Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(592)

Unified Diff: components/data_reduction_proxy/core/browser/data_reduction_proxy_interceptor.cc

Issue 958163004: Make Data Saver proxy bypass logic apply to redirects. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Suppress size_t to int warnings in gyp/gn files (crbug 167187) Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: components/data_reduction_proxy/core/browser/data_reduction_proxy_interceptor.cc
diff --git a/components/data_reduction_proxy/core/browser/data_reduction_proxy_interceptor.cc b/components/data_reduction_proxy/core/browser/data_reduction_proxy_interceptor.cc
index afab0b5507a498537478b72fa1cef5a293f61192..773015c8ebf22883dc47cb1c0e513e30520aaf18 100644
--- a/components/data_reduction_proxy/core/browser/data_reduction_proxy_interceptor.cc
+++ b/components/data_reduction_proxy/core/browser/data_reduction_proxy_interceptor.cc
@@ -34,9 +34,23 @@ net::URLRequestJob* DataReductionProxyInterceptor::MaybeInterceptRequest(
return nullptr;
}
+net::URLRequestJob* DataReductionProxyInterceptor::MaybeInterceptRedirect(
+ net::URLRequest* request,
+ net::NetworkDelegate* network_delegate,
+ const GURL& location) const {
+ return MaybeInterceptResponseOrRedirect(request, network_delegate);
+}
+
net::URLRequestJob* DataReductionProxyInterceptor::MaybeInterceptResponse(
net::URLRequest* request,
net::NetworkDelegate* network_delegate) const {
+ return MaybeInterceptResponseOrRedirect(request, network_delegate);
+}
+
+net::URLRequestJob*
+DataReductionProxyInterceptor::MaybeInterceptResponseOrRedirect(
+ net::URLRequest* request,
+ net::NetworkDelegate* network_delegate) const {
if (request->response_info().was_cached)
return nullptr;
DataReductionProxyBypassType bypass_type = BYPASS_EVENT_TYPE_MAX;

Powered by Google App Engine
This is Rietveld 408576698