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

Unified Diff: components/metrics/metrics_log.cc

Issue 2358223002: Add log date to the metrics log (Closed)
Patch Set: 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/metrics/metrics_log.cc
diff --git a/components/metrics/metrics_log.cc b/components/metrics/metrics_log.cc
index 3824762e217d71c3d5d49fd925ab43207a558366..f74e5a767243f58dbe17392628195f519660c7b0 100644
--- a/components/metrics/metrics_log.cc
+++ b/components/metrics/metrics_log.cc
@@ -427,6 +427,9 @@ void MetricsLog::RecordEnvironment(
local_state->SetString(prefs::kStabilitySavedSystemProfileHash,
ComputeSHA1(serialized_system_profile));
}
+
+ system_profile->set_log_date(
+ (base::Time::Now() - base::Time::UnixEpoch()).InSeconds());
}
bool MetricsLog::LoadSavedEnvironmentFromPrefs(std::string* app_version) {
« no previous file with comments | « no previous file | components/metrics/metrics_log_unittest.cc » ('j') | components/metrics/proto/system_profile.proto » ('J')

Powered by Google App Engine
This is Rietveld 408576698