From da549b9a25b326c0ddc8e43365b2f6a66de750a1 Mon Sep 17 00:00:00 2001 From: "bryner@chromium.org" Date: Sat, 29 Oct 2011 08:00:45 +0000 Subject: Include the HTTP status code as a feature in the ClientPhishingRequest. BUG=none TEST=BrowserFeatureExtractorTest Review URL: http://codereview.chromium.org/8400050 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@107867 0039d316-1c4b-4281-b951-d872f2087c98 --- chrome/browser/safe_browsing/browser_feature_extractor.cc | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'chrome/browser/safe_browsing/browser_feature_extractor.cc') diff --git a/chrome/browser/safe_browsing/browser_feature_extractor.cc b/chrome/browser/safe_browsing/browser_feature_extractor.cc index a5e2e6b..5dd4186 100644 --- a/chrome/browser/safe_browsing/browser_feature_extractor.cc +++ b/chrome/browser/safe_browsing/browser_feature_extractor.cc @@ -28,7 +28,7 @@ namespace safe_browsing { -BrowseInfo::BrowseInfo() {} +BrowseInfo::BrowseInfo() : http_status_code(0) {} BrowseInfo::~BrowseInfo() {} @@ -232,7 +232,9 @@ void BrowserFeatureExtractor::ExtractBrowseInfoFeatures( static_cast(info.unsafe_resource->threat_type), request); } - + if (info.http_status_code != 0) { + AddFeature(features::kHttpStatusCode, info.http_status_code, request); + } } void BrowserFeatureExtractor::StartExtractFeatures( -- cgit v1.1