Index: chrome/browser/renderer_host/data_reduction_proxy_resource_throttle_android.cc |
diff --git a/chrome/browser/renderer_host/data_reduction_proxy_resource_throttle_android.cc b/chrome/browser/renderer_host/data_reduction_proxy_resource_throttle_android.cc |
index 6bda059f50c37b77e406f267a5de06c4b66e217e..d433fac26e73e0f990e0d0255629a21a0bf37ef7 100644 |
--- a/chrome/browser/renderer_host/data_reduction_proxy_resource_throttle_android.cc |
+++ b/chrome/browser/renderer_host/data_reduction_proxy_resource_throttle_android.cc |
@@ -43,10 +43,15 @@ DataReductionProxyResourceThrottleFactory::CreateResourceThrottle( |
content::ResourceType resource_type, |
SafeBrowsingService* service) { |
#if defined(SAFE_BROWSING_DB_LOCAL) || defined(SAFE_BROWSING_DB_REMOTE) |
+ // Send requests through Safe Browsing if we can't process them. |
ProfileIOData* io_data = ProfileIOData::FromResourceContext(resource_context); |
if (io_data->IsOffTheRecord() || !io_data->IsDataReductionProxyEnabled() || |
- request->url().SchemeIsSecure()) |
- return new SafeBrowsingResourceThrottle(request, resource_type, service); |
+ request->url().SchemeIsSecure()) { |
+ // *this is already registered as the SafeBrowsingResourceThrottleFactory, |
+ // so need to bypass that and use its base implementation. |
+ return SafeBrowsingResourceThrottleFactory::CreateWithoutRegisteredFactory( |
+ request, resource_type, service); |
+ } |
#endif |
return new DataReductionProxyResourceThrottle(request, resource_type, |
service); |