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

Unified Diff: ios/web/web_thread_impl.cc

Issue 2536803002: Remove ThreadRestrictions::ScopedAllowSingleton. (Closed)
Patch Set: Created 4 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 | « base/threading/thread_restrictions.h ('k') | net/base/keygen_handler_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ios/web/web_thread_impl.cc
diff --git a/ios/web/web_thread_impl.cc b/ios/web/web_thread_impl.cc
index d835251083ce8fd0d0ca5923f4945c96c3480f8d..2a28556be4567f046cf6e19adab71aef600b04e7 100644
--- a/ios/web/web_thread_impl.cc
+++ b/ios/web/web_thread_impl.cc
@@ -368,11 +368,6 @@ bool WebThread::IsThreadInitialized(ID identifier) {
// static
bool WebThread::CurrentlyOn(ID identifier) {
- // This shouldn't use MessageLoop::current() since it uses LazyInstance which
- // may be deleted by ~AtExitManager when a WorkerPool thread calls this
- // function.
- // http://crbug.com/63678
- base::ThreadRestrictions::ScopedAllowSingleton allow_singleton;
WebThreadGlobals& globals = g_globals.Get();
base::AutoLock lock(globals.lock);
DCHECK(identifier >= 0 && identifier < ID_COUNT);
@@ -456,11 +451,6 @@ bool WebThread::GetCurrentThreadIdentifier(ID* identifier) {
if (g_globals == nullptr)
return false;
- // This shouldn't use MessageLoop::current() since it uses LazyInstance which
- // may be deleted by ~AtExitManager when a WorkerPool thread calls this
- // function.
- // http://crbug.com/63678
- base::ThreadRestrictions::ScopedAllowSingleton allow_singleton;
base::MessageLoop* cur_message_loop = base::MessageLoop::current();
WebThreadGlobals& globals = g_globals.Get();
for (int i = 0; i < ID_COUNT; ++i) {
« no previous file with comments | « base/threading/thread_restrictions.h ('k') | net/base/keygen_handler_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698