summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--base/observer_list_threadsafe.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/base/observer_list_threadsafe.h b/base/observer_list_threadsafe.h
index 113805f..70a76c8 100644
--- a/base/observer_list_threadsafe.h
+++ b/base/observer_list_threadsafe.h
@@ -64,6 +64,9 @@ class ObserverListThreadSafe :
void AddObserver(ObserverType* obs) {
ObserverList<ObserverType>* list = NULL;
MessageLoop* loop = MessageLoop::current();
+ // TODO(mbelshe): Get rid of this check. Its needed right now because
+ // Time currently triggers usage of the ObserverList.
+ // And unittests use time without a MessageLoop.
if (!loop)
return; // Some unittests may access this without a message loop.
{