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

Unified Diff: base/prefs/json_pref_store.cc

Issue 226633002: Commit changes after a reset. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Don't commit, just schedule. Created 6 years, 8 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
« no previous file with comments | « no previous file | base/prefs/pref_filter.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/prefs/json_pref_store.cc
diff --git a/base/prefs/json_pref_store.cc b/base/prefs/json_pref_store.cc
index 0703075846fd59f95344060ecf8d6aafa60d8911..b0a16cc11431e01fd8661949388c11cdc972f156 100644
--- a/base/prefs/json_pref_store.cc
+++ b/base/prefs/json_pref_store.cc
@@ -314,8 +314,8 @@ void JsonPrefStore::OnFileRead(base::Value* value_owned,
NOTREACHED() << "Unknown error: " << error;
}
- if (pref_filter_)
- pref_filter_->FilterOnLoad(prefs_.get());
+ if (pref_filter_ && pref_filter_->FilterOnLoad(prefs_.get()))
+ writer_.ScheduleWrite(this);
if (error_delegate_.get() && error != PREF_READ_ERROR_NONE)
error_delegate_->OnError(error);
« no previous file with comments | « no previous file | base/prefs/pref_filter.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698