summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjar@chromium.org <jar@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-06-19 06:10:37 +0000
committerjar@chromium.org <jar@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-06-19 06:10:37 +0000
commitae155cb97116363c783eb4e5c6277bef8336b0cf (patch)
tree266150b16b777753f4544886bf6d30d9e85549e5
parent2f1eec4257cf722860f2b64454291dc81f6f1971 (diff)
downloadchromium_src-ae155cb97116363c783eb4e5c6277bef8336b0cf.zip
chromium_src-ae155cb97116363c783eb4e5c6277bef8336b0cf.tar.gz
chromium_src-ae155cb97116363c783eb4e5c6277bef8336b0cf.tar.bz2
When we upgrade, discard all uploadable stats, including old logs
We already discard all stability info when we do an upgrade to a new version, as there is less concern about stats from old versions. This change just adds the list of "old logs" (gathered in previous sessions, presumably with an old version) to the list of data that is discarded. BUG=14657 r=evanm Review URL: http://codereview.chromium.org/131089 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18794 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r--chrome/browser/metrics/metrics_service.cc8
1 files changed, 8 insertions, 0 deletions
diff --git a/chrome/browser/metrics/metrics_service.cc b/chrome/browser/metrics/metrics_service.cc
index 50b3af3..57a326b 100644
--- a/chrome/browser/metrics/metrics_service.cc
+++ b/chrome/browser/metrics/metrics_service.cc
@@ -372,6 +372,14 @@ void MetricsService::DiscardOldStabilityStats(PrefService* local_state) {
local_state->SetString(prefs::kStabilityUptimeSec, L"0");
local_state->ClearPref(prefs::kStabilityPluginStats);
+
+ ListValue* unsent_initial_logs = local_state->GetMutableList(
+ prefs::kMetricsInitialLogs);
+ unsent_initial_logs->Clear();
+
+ ListValue* unsent_ongoing_logs = local_state->GetMutableList(
+ prefs::kMetricsOngoingLogs);
+ unsent_ongoing_logs->Clear();
}
MetricsService::MetricsService()