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

Unified Diff: chrome/installer/util/google_update_settings.cc

Issue 2222903004: Clear client id prefs when opting out of UMA. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove early return in ForceClientIdCreation(). Created 4 years, 4 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/installer/util/google_update_settings.cc
diff --git a/chrome/installer/util/google_update_settings.cc b/chrome/installer/util/google_update_settings.cc
index 0ab8bddaf5f1149c52008f1faa8608eda3984124..5c6f13bd068d638f8530603f82f3730556991085 100644
--- a/chrome/installer/util/google_update_settings.cc
+++ b/chrome/installer/util/google_update_settings.cc
@@ -329,6 +329,11 @@ bool GoogleUpdateSettings::SetCollectStatsConsentAtLevel(bool system_install,
<< google_update::kRegUsageStatsField << " in key " << reg_path
<< "; result: " << result;
}
+
+ // When opting out, clear registry backup of client id and related values.
+ if (result == ERROR_SUCCESS && !consented)
+ GoogleUpdateSettings::StoreMetricsClientInfo(metrics::ClientInfo());
grt (UTC plus 2) 2016/08/12 19:43:32 nit: omit "GoogleUpdateSettings::"
Alexei Svitkine (slow) 2016/08/12 22:29:58 Done.
+
return (result == ERROR_SUCCESS);
}
« no previous file with comments | « chrome/browser/metrics/metrics_reporting_state.cc ('k') | chrome/installer/util/google_update_settings_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698