Index: chrome/browser/browser_process_impl.cc |
diff --git a/chrome/browser/browser_process_impl.cc b/chrome/browser/browser_process_impl.cc |
index 9ecbacfbcd9b1e7367a7594da86e9df6e1fa3ebe..727ecfe20feb26a71b4df5f777510088bbbfc34d 100644 |
--- a/chrome/browser/browser_process_impl.cc |
+++ b/chrome/browser/browser_process_impl.cc |
@@ -285,10 +285,6 @@ void BrowserProcessImpl::StartTearDown() { |
platform_part()->StartTearDown(); |
-#if defined(ENABLE_WEBRTC) |
- webrtc_log_uploader_.reset(); |
-#endif |
- |
if (local_state()) |
local_state()->CommitPendingWrite(); |
} |
@@ -297,6 +293,11 @@ void BrowserProcessImpl::PostDestroyThreads() { |
// With the file_thread_ flushed, we can release any icon resources. |
icon_manager_.reset(); |
+#if defined(ENABLE_WEBRTC) |
+ // Must outlive the file thread. |
+ webrtc_log_uploader_.reset(); |
+#endif |
+ |
// Reset associated state right after actual thread is stopped, |
// as io_thread_.global_ cleanup happens in CleanUp on the IO |
// thread, i.e. as the thread exits its message loop. |