Index: chrome/browser/managed_mode/managed_mode_navigation_observer.cc |
diff --git a/chrome/browser/managed_mode/managed_mode_navigation_observer.cc b/chrome/browser/managed_mode/managed_mode_navigation_observer.cc |
index bd06cafedd2b045038b760ddc2abf159ce568eb8..ceddba64b1879de04938e76669e293c8da427ad4 100644 |
--- a/chrome/browser/managed_mode/managed_mode_navigation_observer.cc |
+++ b/chrome/browser/managed_mode/managed_mode_navigation_observer.cc |
@@ -13,6 +13,7 @@ |
#include "chrome/browser/history/history_types.h" |
#include "chrome/browser/infobars/confirm_infobar_delegate.h" |
#include "chrome/browser/infobars/infobar.h" |
+#include "chrome/browser/infobars/infobar_manager.h" |
#include "chrome/browser/infobars/infobar_service.h" |
#include "chrome/browser/managed_mode/managed_mode_interstitial.h" |
#include "chrome/browser/managed_mode/managed_mode_resource_throttle.h" |
@@ -188,7 +189,9 @@ void ManagedModeNavigationObserver::ProvisionalChangeToMainFrameUrl( |
return; |
// If we shouldn't have a warn infobar remove it here. |
- InfoBarService::FromWebContents(web_contents())->RemoveInfoBar(warn_infobar_); |
+ InfoBarManager* infobar_manager = |
+ InfoBarService::FromWebContents(web_contents())->infobar_manager(); |
+ infobar_manager->RemoveInfoBar(warn_infobar_); |
warn_infobar_ = NULL; |
} |