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

Unified Diff: components/history/core/browser/history_database.cc

Issue 2720613002: Downloads: Added transient flag to download item and download database (Closed)
Patch Set: Renamed to transient Created 3 years, 9 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/history/core/browser/history_database.cc
diff --git a/components/history/core/browser/history_database.cc b/components/history/core/browser/history_database.cc
index b7b90b06ac892849e2adef55c77460909da100e9..72b548e171856c93681961a6a75c7119cd08d9b7 100644
--- a/components/history/core/browser/history_database.cc
+++ b/components/history/core/browser/history_database.cc
@@ -570,6 +570,15 @@ sql::InitStatus HistoryDatabase::EnsureCurrentVersion() {
meta_table_.SetVersionNumber(cur_version);
}
+ if (cur_version == 35) {
+ if (!MigrateDownloadTransient()) {
+ LOG(WARNING) << "Unable to migrate to version 35";
+ return sql::INIT_FAILURE;
+ }
+ cur_version++;
+ meta_table_.SetVersionNumber(cur_version);
+ }
+
// When the version is too old, we just try to continue anyway, there should
// not be a released product that makes a database too old for us to handle.
LOG_IF(WARNING, cur_version < GetCurrentVersion()) <<

Powered by Google App Engine
This is Rietveld 408576698