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

Unified Diff: components/prefs/json_pref_store.cc

Issue 2204943002: Integrate registry_hash_store_contents with the rest of tracked prefs. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Apply fixes from #10 Created 4 years, 3 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/prefs/json_pref_store.cc
diff --git a/components/prefs/json_pref_store.cc b/components/prefs/json_pref_store.cc
index 884829a7ac0392dd603417fba068896be475d372..c6368dc0c92ad4f880e4607002b59abfe61e638b 100644
--- a/components/prefs/json_pref_store.cc
+++ b/components/prefs/json_pref_store.cc
@@ -462,8 +462,12 @@ bool JsonPrefStore::SerializeData(std::string* output) {
write_count_histogram_.RecordWriteOccured();
- if (pref_filter_)
- pref_filter_->FilterSerializeData(prefs_.get());
+ if (pref_filter_) {
+ base::Callback<void(bool)> pref_filter_post_write_callback =
+ pref_filter_->FilterSerializeData(prefs_.get());
+ if (!pref_filter_post_write_callback.is_null())
+ RegisterOnNextWriteSynchronousCallback(pref_filter_post_write_callback);
+ }
JSONStringValueSerializer serializer(output);
// Not pretty-printing prefs shrinks pref file size by ~30%. To obtain

Powered by Google App Engine
This is Rietveld 408576698