Index: base/message_loop.cc |
diff --git a/base/message_loop.cc b/base/message_loop.cc |
index 542802672927403a6d57f35ed65f11bc5d10d502..0a6bf6c03179c5afbb92890550426b9089321314 100644 |
--- a/base/message_loop.cc |
+++ b/base/message_loop.cc |
@@ -251,9 +251,12 @@ void MessageLoop::EnableHistogrammer(bool enable) { |
} |
// static |
-void MessageLoop::InitMessagePumpForUIFactory(MessagePumpFactory* factory) { |
- DCHECK(!message_pump_for_ui_factory_); |
+bool MessageLoop::InitMessagePumpForUIFactory(MessagePumpFactory* factory) { |
+ if (message_pump_for_ui_factory_) |
+ return false; |
+ |
message_pump_for_ui_factory_ = factory; |
+ return true; |
} |
void MessageLoop::AddDestructionObserver( |