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

Unified Diff: components/network_time/network_time_tracker.cc

Issue 2641293002: Add data usage tracking for chrome services (Closed)
Patch Set: Created 3 years, 11 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
« no previous file with comments | « components/network_time/DEPS ('k') | tools/metrics/histograms/histograms.xml » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/network_time/network_time_tracker.cc
diff --git a/components/network_time/network_time_tracker.cc b/components/network_time/network_time_tracker.cc
index f1017741e325f80a233ae823dc25ac20f9532233..10cd0912517fc794093b168d6c3dd7823688545a 100644
--- a/components/network_time/network_time_tracker.cc
+++ b/components/network_time/network_time_tracker.cc
@@ -20,6 +20,7 @@
#include "base/time/tick_clock.h"
#include "build/build_config.h"
#include "components/client_update_protocol/ecdsa.h"
+#include "components/data_use_measurement/core/data_use_user_data.h"
#include "components/network_time/network_time_pref_names.h"
#include "components/prefs/pref_registry_simple.h"
#include "components/prefs/pref_service.h"
@@ -464,6 +465,9 @@ void NetworkTimeTracker::CheckTime() {
DVLOG(1) << "tried to make fetch happen; failed";
return;
}
+ data_use_measurement::DataUseUserData::AttachToFetcher(
+ time_fetcher_.get(),
+ data_use_measurement::DataUseUserData::NETWORK_TIME_TRACKER);
time_fetcher_->SaveResponseWithWriter(
std::unique_ptr<net::URLFetcherResponseWriter>(
new SizeLimitingStringWriter(max_response_size_)));
« no previous file with comments | « components/network_time/DEPS ('k') | tools/metrics/histograms/histograms.xml » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698