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

Unified Diff: mojo/message_pump/handle_watcher.cc

Issue 1471123002: Don't leak the WatcherThreadManager background thread. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: also posix Created 5 years, 1 month 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 | « mojo/edk/system/raw_channel.cc ('k') | mojo/message_pump/message_pump_mojo.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/message_pump/handle_watcher.cc
diff --git a/mojo/message_pump/handle_watcher.cc b/mojo/message_pump/handle_watcher.cc
index a8d007a0e3360b668f45894114d52d984ac11e9d..b2320cc5b96ee7e96f4e458c31e63ef65b5d7799 100644
--- a/mojo/message_pump/handle_watcher.cc
+++ b/mojo/message_pump/handle_watcher.cc
@@ -223,13 +223,7 @@ WatcherThreadManager::~WatcherThreadManager() {
}
WatcherThreadManager* WatcherThreadManager::GetInstance() {
- // We need to leak this because otherwise when the process dies, AtExitManager
- // waits for destruction which waits till the handle watcher thread is joined.
- // But that can't happen since the pump uses mojo message pipes to wake up the
- // pump. Since mojo EDK has been shutdown already, this never completes.
- return base::Singleton<WatcherThreadManager,
- base::LeakySingletonTraits<WatcherThreadManager>>::
- get();
+ return base::Singleton<WatcherThreadManager>::get();
}
WatcherID WatcherThreadManager::StartWatching(
« no previous file with comments | « mojo/edk/system/raw_channel.cc ('k') | mojo/message_pump/message_pump_mojo.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698