Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(396)

Unified Diff: components/safe_browsing_db/v4_local_database_manager.cc

Issue 2561053002: V4Only: In V4Only mode use PVer4 for all SafeBrowsing operations (Closed)
Patch Set: Fix my comments from 2533993004 Created 4 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: components/safe_browsing_db/v4_local_database_manager.cc
diff --git a/components/safe_browsing_db/v4_local_database_manager.cc b/components/safe_browsing_db/v4_local_database_manager.cc
index ce0831247ec8a796607415a0af839678f6ba3522..45748e4601eec7353fc74d4d88140c1aaccc994e 100644
--- a/components/safe_browsing_db/v4_local_database_manager.cc
+++ b/components/safe_browsing_db/v4_local_database_manager.cc
@@ -81,13 +81,15 @@ ThreatSeverity GetThreatSeverity(const ListIdentifier& list_id) {
switch (list_id.threat_type()) {
case MALWARE_THREAT:
case SOCIAL_ENGINEERING_PUBLIC:
+ case MALICIOUS_BINARY:
return 0;
case UNWANTED_SOFTWARE:
return 1;
case API_ABUSE:
return 2;
default:
- NOTREACHED() << "Unexpected ThreatType encountered in GetThreatSeverity";
+ NOTREACHED() << "Unexpected ThreatType encountered: "
+ << list_id.threat_type();
return kLeastSeverity;
}
}
@@ -435,6 +437,7 @@ bool V4LocalDatabaseManager::GetPrefixMatches(
const base::TimeTicks before = TimeTicks::Now();
if (check->client_callback_type == ClientCallbackType::CHECK_BROWSE_URL ||
check->client_callback_type == ClientCallbackType::CHECK_DOWNLOAD_URLS ||
+ check->client_callback_type == ClientCallbackType::CHECK_RESOURCE_URL ||
check->client_callback_type == ClientCallbackType::CHECK_EXTENSION_IDS ||
check->client_callback_type == ClientCallbackType::CHECK_OTHER) {
DCHECK(!check->full_hashes.empty());
@@ -450,7 +453,7 @@ bool V4LocalDatabaseManager::GetPrefixMatches(
}
}
} else {
- NOTREACHED() << "Unexpected client_callback_type encountered";
+ NOTREACHED() << "Unexpected client_callback_type encountered.";
}
// TODO(vakh): Only log SafeBrowsing.V4GetPrefixMatches.Time once PVer3 code

Powered by Google App Engine
This is Rietveld 408576698