diff options
Diffstat (limited to 'chrome')
-rw-r--r-- | chrome/browser/net/dns_global.cc | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/chrome/browser/net/dns_global.cc b/chrome/browser/net/dns_global.cc index 139cfa6..61e7ec1 100644 --- a/chrome/browser/net/dns_global.cc +++ b/chrome/browser/net/dns_global.cc @@ -286,10 +286,13 @@ class OffTheRecordObserver : public NotificationObserver { ~OffTheRecordObserver() { } void Register() { - registrar_.Add(this, NotificationType::BROWSER_CLOSED, - NotificationService::AllSources()); - registrar_.Add(this, NotificationType::BROWSER_OPENED, - NotificationService::AllSources()); + // TODO(pkasting): This test should not be necessary. See crbug.com/12475. + if (registrar_.IsEmpty()) { + registrar_.Add(this, NotificationType::BROWSER_CLOSED, + NotificationService::AllSources()); + registrar_.Add(this, NotificationType::BROWSER_OPENED, + NotificationService::AllSources()); + } } void Observe(NotificationType type, const NotificationSource& source, |