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

Unified Diff: ios/chrome/browser/application_context_impl.cc

Issue 1835823002: network_time_tracker: add temporary time protocol. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: lint Created 4 years, 7 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/ssl_errors/error_classification_unittest.cc ('k') | ios/chrome/test/DEPS » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ios/chrome/browser/application_context_impl.cc
diff --git a/ios/chrome/browser/application_context_impl.cc b/ios/chrome/browser/application_context_impl.cc
index 6f17dc2bfd5ac158c6b7717246c302eca4536079..d38e98f17fa9b1866cd945f01a30007ebf0057ec 100644
--- a/ios/chrome/browser/application_context_impl.cc
+++ b/ios/chrome/browser/application_context_impl.cc
@@ -105,12 +105,13 @@ void ApplicationContextImpl::PreMainMessageLoopRun() {
void ApplicationContextImpl::StartTearDown() {
DCHECK(thread_checker_.CalledOnValidThread());
- // We need to destroy the MetricsServicesManager before the IO thread gets
- // destroyed, since the destructor can call the URLFetcher destructor, which
- // does a PostDelayedTask operation on the IO thread. (The IO thread will
- // handle that URLFetcher operation before going away.)
+ // We need to destroy the MetricsServicesManager and NetworkTimeTracker before
+ // the IO thread gets destroyed, since the destructor can call the URLFetcher
+ // destructor, which does a PostDelayedTask operation on the IO thread. (The
+ // IO thread will handle that URLFetcher operation before going away.)
metrics_services_manager_.reset();
+ network_time_tracker_.reset();
// Need to clear browser states before the IO thread.
chrome_browser_state_manager_.reset();
@@ -254,7 +255,8 @@ ApplicationContextImpl::GetNetworkTimeTracker() {
if (!network_time_tracker_) {
network_time_tracker_.reset(new network_time::NetworkTimeTracker(
base::WrapUnique(new base::DefaultClock),
- base::WrapUnique(new base::DefaultTickClock), GetLocalState()));
+ base::WrapUnique(new base::DefaultTickClock), GetLocalState(),
+ GetSystemURLRequestContext()));
}
return network_time_tracker_.get();
}
« no previous file with comments | « components/ssl_errors/error_classification_unittest.cc ('k') | ios/chrome/test/DEPS » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698