summaryrefslogtreecommitdiffstats
path: root/chrome
diff options
context:
space:
mode:
Diffstat (limited to 'chrome')
-rw-r--r--chrome/browser/ui/tab_contents/tab_contents_wrapper.cc2
-rw-r--r--chrome/renderer/chrome_render_view_observer.cc2
2 files changed, 3 insertions, 1 deletions
diff --git a/chrome/browser/ui/tab_contents/tab_contents_wrapper.cc b/chrome/browser/ui/tab_contents/tab_contents_wrapper.cc
index 4e42298..348b223 100644
--- a/chrome/browser/ui/tab_contents/tab_contents_wrapper.cc
+++ b/chrome/browser/ui/tab_contents/tab_contents_wrapper.cc
@@ -641,6 +641,7 @@ void TabContentsWrapper::UpdateRendererPreferences() {
}
void TabContentsWrapper::UpdateSafebrowsingDetectionHost() {
+#if defined(ENABLE_SAFE_BROWSING)
PrefService* prefs = profile()->GetPrefs();
bool safe_browsing = prefs->GetBoolean(prefs::kSafeBrowsingEnabled);
if (safe_browsing &&
@@ -654,6 +655,7 @@ void TabContentsWrapper::UpdateSafebrowsingDetectionHost() {
}
render_view_host()->Send(
new ViewMsg_SetClientSidePhishingDetection(routing_id(), safe_browsing));
+#endif
}
void TabContentsWrapper::RemoveInfoBarInternal(InfoBarDelegate* delegate,
diff --git a/chrome/renderer/chrome_render_view_observer.cc b/chrome/renderer/chrome_render_view_observer.cc
index 73e8c94..046e965 100644
--- a/chrome/renderer/chrome_render_view_observer.cc
+++ b/chrome/renderer/chrome_render_view_observer.cc
@@ -348,7 +348,7 @@ void ChromeRenderViewObserver::OnSetAllowRunningInsecureContent(bool allow) {
void ChromeRenderViewObserver::OnSetClientSidePhishingDetection(
bool enable_phishing_detection) {
-#if !defined(OS_CHROMEOS) || !defined(ENABLE_SAFE_BROWSING)
+#if defined(ENABLE_SAFE_BROWSING) && !defined(OS_CHROMEOS)
phishing_classifier_ = enable_phishing_detection ?
safe_browsing::PhishingClassifierDelegate::Create(
render_view(), NULL) :