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

Unified Diff: chrome/browser/protector/protected_prefs_watcher.cc

Issue 9748016: [protector] Added UI for invalid Preferences backup case. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Fix unit-test. Created 8 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: chrome/browser/protector/protected_prefs_watcher.cc
diff --git a/chrome/browser/protector/protected_prefs_watcher.cc b/chrome/browser/protector/protected_prefs_watcher.cc
index 218a33096d132fe53e3840940fb7fdaf737f58a7..8fedbe063c178899c2d1a449aea68e1f20958cdb 100644
--- a/chrome/browser/protector/protected_prefs_watcher.cc
+++ b/chrome/browser/protector/protected_prefs_watcher.cc
@@ -232,8 +232,9 @@ void ProtectedPrefsWatcher::ValidateBackup() {
kProtectorErrorCount);
} else {
LOG(WARNING) << "Invalid backup signature";
- // Further changes to protected prefs will overwrite the signature.
is_backup_valid_ = false;
+ // The whole backup has been compromised, overwrite it.
+ InitBackup();
UMA_HISTOGRAM_ENUMERATION(
kProtectorHistogramPrefs,
kProtectorErrorBackupInvalid,
« no previous file with comments | « chrome/browser/protector/protected_prefs_watcher.h ('k') | chrome/browser/protector/protected_prefs_watcher_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698