summaryrefslogtreecommitdiffstats
path: root/components/cronet/android/cronet_data_reduction_proxy.cc
diff options
context:
space:
mode:
authorryansturm <ryansturm@chromium.org>2016-02-29 16:13:21 -0800
committerCommit bot <commit-bot@chromium.org>2016-03-01 00:15:41 +0000
commit4e254a6cef98f089a02123d32a22672b3e900aa7 (patch)
tree399890f9bc92c9e28ad980ec975c8014aec86c6d /components/cronet/android/cronet_data_reduction_proxy.cc
parentbd162ec5dcf4377d94bc08b871a64945a2793612 (diff)
downloadchromium_src-4e254a6cef98f089a02123d32a22672b3e900aa7.zip
chromium_src-4e254a6cef98f089a02123d32a22672b3e900aa7.tar.gz
chromium_src-4e254a6cef98f089a02123d32a22672b3e900aa7.tar.bz2
Passing in a Data Reduction Proxy Delegate from Cronet with Data Reduction Proxy Enabled
The Cronet test, CronetUrlRequestContextTest#testDataReductionProxyEnabled started to fail as a result of https://codereview.chromium.org/1680893002 This fix creates a DataReductionProxyDelegate for Cronet when built with the data_reduction build flag. The test relied on having DataReductionProxyNetworkDelegate handle the proxy resolution before, but that work is now handled by DataReductionProxyDelegate. BUG=589600 Review URL: https://codereview.chromium.org/1725123005 Cr-Commit-Position: refs/heads/master@{#378337}
Diffstat (limited to 'components/cronet/android/cronet_data_reduction_proxy.cc')
-rw-r--r--components/cronet/android/cronet_data_reduction_proxy.cc5
1 files changed, 5 insertions, 0 deletions
diff --git a/components/cronet/android/cronet_data_reduction_proxy.cc b/components/cronet/android/cronet_data_reduction_proxy.cc
index 360862fb..76321be 100644
--- a/components/cronet/android/cronet_data_reduction_proxy.cc
+++ b/components/cronet/android/cronet_data_reduction_proxy.cc
@@ -11,6 +11,7 @@
#include "base/single_thread_task_runner.h"
#include "components/cronet/android/cronet_in_memory_pref_store.h"
#include "components/data_reduction_proxy/core/browser/data_reduction_proxy_compression_stats.h"
+#include "components/data_reduction_proxy/core/browser/data_reduction_proxy_delegate.h"
#include "components/data_reduction_proxy/core/browser/data_reduction_proxy_io_data.h"
#include "components/data_reduction_proxy/core/browser/data_reduction_proxy_network_delegate.h"
#include "components/data_reduction_proxy/core/browser/data_reduction_proxy_prefs.h"
@@ -106,6 +107,10 @@ CronetDataReductionProxy::CreateNetworkDelegate(
false /* No bypass UMA */);
}
+scoped_ptr<net::ProxyDelegate> CronetDataReductionProxy::CreateProxyDelegate() {
+ return io_data_->CreateProxyDelegate();
+}
+
scoped_ptr<net::URLRequestInterceptor>
CronetDataReductionProxy::CreateInterceptor() {
return io_data_->CreateInterceptor();