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

Unified Diff: components/password_manager/core/browser/affiliation_database.cc

Issue 1072413003: Add foundation for trimming the AffiliationDatabase. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Keep noncontroversial parts. Created 5 years, 7 months 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/password_manager/core/browser/affiliation_database.cc
diff --git a/components/password_manager/core/browser/affiliation_database.cc b/components/password_manager/core/browser/affiliation_database.cc
index 0757d711f339c90de27757c22a8af6ff35d70f6b..bab8f36642207db092188730dd226ce824b2932f 100644
--- a/components/password_manager/core/browser/affiliation_database.cc
+++ b/components/password_manager/core/browser/affiliation_database.cc
@@ -214,6 +214,12 @@ void AffiliationDatabase::StoreAndRemoveConflicting(
transaction.Commit();
}
+// static
+void AffiliationDatabase::Delete(const base::FilePath& path) {
+ bool success = sql::Connection::Delete(path);
+ DCHECK(success);
+}
+
bool AffiliationDatabase::CreateTablesAndIndicesIfNeeded() {
if (!sql_connection_->Execute(
"CREATE TABLE IF NOT EXISTS eq_classes("

Powered by Google App Engine
This is Rietveld 408576698