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

Unified Diff: chrome/browser/chrome_browser_main_android.cc

Issue 10979048: Fix potential threading issues in NetworkChangeNotifierAndroid. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 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
« no previous file with comments | « no previous file | content/shell/shell_browser_main_parts.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/chrome_browser_main_android.cc
diff --git a/chrome/browser/chrome_browser_main_android.cc b/chrome/browser/chrome_browser_main_android.cc
index d99c140119ddc3fbe21243d2de8fcbfaa9424906..5b7ab0b57204e0ca3f52ff3e5431b809bfe457da 100644
--- a/chrome/browser/chrome_browser_main_android.cc
+++ b/chrome/browser/chrome_browser_main_android.cc
@@ -18,13 +18,14 @@ ChromeBrowserMainPartsAndroid::~ChromeBrowserMainPartsAndroid() {
}
void ChromeBrowserMainPartsAndroid::PreEarlyInitialization() {
- net::NetworkChangeNotifier::SetFactory(
- new net::NetworkChangeNotifierFactoryAndroid());
-
// Chrome on Android does not use default MessageLoop. It has its own
// Android specific MessageLoop.
DCHECK(!main_message_loop_.get());
main_message_loop_.reset(new MessageLoop(MessageLoop::TYPE_UI));
+ net::NetworkChangeNotifier::SetFactory(
+ new net::NetworkChangeNotifierFactoryAndroid(
+ MessageLoop::current()->message_loop_proxy()));
+
MessageLoopForUI::current()->Start();
ChromeBrowserMainParts::PreEarlyInitialization();
« no previous file with comments | « no previous file | content/shell/shell_browser_main_parts.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698