| Index: chrome/browser/io_thread.cc
|
| diff --git a/chrome/browser/io_thread.cc b/chrome/browser/io_thread.cc
|
| index 2a116ed77554707c3dab8c12be04f089de4ed2fc..169973f78f68e10e3d760ee1acfcc0e314eb82f1 100644
|
| --- a/chrome/browser/io_thread.cc
|
| +++ b/chrome/browser/io_thread.cc
|
| @@ -40,7 +40,11 @@
|
| #include "chrome/common/chrome_switches.h"
|
| #include "chrome/common/chrome_version_info.h"
|
| #include "chrome/common/pref_names.h"
|
| +#include "components/data_reduction_proxy/browser/data_reduction_proxy_auth_request_handler.h"
|
| +#include "components/data_reduction_proxy/browser/data_reduction_proxy_params.h"
|
| #include "components/data_reduction_proxy/browser/data_reduction_proxy_prefs.h"
|
| +#include "components/data_reduction_proxy/browser/data_reduction_proxy_protocol.h"
|
| +#include "components/data_reduction_proxy/browser/data_reduction_proxy_settings.h"
|
| #include "components/policy/core/common/policy_service.h"
|
| #include "components/variations/variations_associated_data.h"
|
| #include "content/public/browser/browser_thread.h"
|
| @@ -91,13 +95,6 @@
|
| #include "net/ocsp/nss_ocsp.h"
|
| #endif
|
|
|
| -#if defined(OS_ANDROID) || defined(OS_IOS)
|
| -#include "components/data_reduction_proxy/browser/data_reduction_proxy_auth_request_handler.h"
|
| -#include "components/data_reduction_proxy/browser/data_reduction_proxy_params.h"
|
| -#include "components/data_reduction_proxy/browser/data_reduction_proxy_protocol.h"
|
| -#include "components/data_reduction_proxy/browser/data_reduction_proxy_settings.h"
|
| -#endif
|
| -
|
| #if defined(OS_CHROMEOS)
|
| #include "chrome/browser/chromeos/login/users/user_manager.h"
|
| #include "chrome/browser/chromeos/net/cert_verify_proc_chromeos.h"
|
| @@ -105,13 +102,10 @@
|
| #endif
|
|
|
| using content::BrowserThread;
|
| -
|
| -#if defined(OS_ANDROID) || defined(OS_IOS)
|
| using data_reduction_proxy::DataReductionProxyAuthRequestHandler;
|
| using data_reduction_proxy::DataReductionProxyParams;
|
| using data_reduction_proxy::DataReductionProxyUsageStats;
|
| using data_reduction_proxy::DataReductionProxySettings;
|
| -#endif
|
|
|
| class SafeBrowsingURLRequestContext;
|
|
|
| @@ -625,11 +619,13 @@ void IOThread::InitAsync() {
|
| }
|
| #endif
|
| globals_->ssl_config_service = GetSSLConfigService();
|
| -#if defined(OS_ANDROID) || defined(OS_IOS)
|
| -#if defined(SPDY_PROXY_AUTH_ORIGIN)
|
| - int drp_flags = DataReductionProxyParams::kFallbackAllowed;
|
| - if (DataReductionProxyParams::IsIncludedInFieldTrial())
|
| - drp_flags |= DataReductionProxyParams::kAllowed;
|
| + int drp_flags = 0;
|
| + // TODO(kundaji): Gate instantitation of all data reduction classes based
|
| + // on this method.
|
| + if (DataReductionProxyParams::IsIncludedInFieldTrial()) {
|
| + drp_flags = DataReductionProxyParams::kAllowed |
|
| + DataReductionProxyParams::kFallbackAllowed;
|
| + }
|
| if (DataReductionProxyParams::IsIncludedInAlternativeFieldTrial())
|
| drp_flags |= DataReductionProxyParams::kAlternativeAllowed;
|
| if (DataReductionProxyParams::IsIncludedInPromoFieldTrial())
|
| @@ -653,8 +649,6 @@ void IOThread::InitAsync() {
|
| globals_->data_reduction_proxy_auth_request_handler.get());
|
| network_delegate->set_on_resolve_proxy_handler(
|
| globals_->on_resolve_proxy_handler);
|
| -#endif // defined(SPDY_PROXY_AUTH_ORIGIN)
|
| -#endif // defined(OS_ANDROID) || defined(OS_IOS)
|
| globals_->http_auth_handler_factory.reset(CreateDefaultAuthHandlerFactory(
|
| globals_->host_resolver.get()));
|
| globals_->http_server_properties.reset(new net::HttpServerPropertiesImpl());
|
| @@ -1091,6 +1085,10 @@ void IOThread::InitSystemRequestContextOnIOThread() {
|
| system_proxy_config_service_.release(),
|
| command_line,
|
| quick_check_enabled_.GetValue()));
|
| + DCHECK(globals_->data_reduction_proxy_params);
|
| + globals_->system_proxy_service->SetDataReductionProxyOrigins(
|
| + globals_->data_reduction_proxy_params->GetDefaultOrigin(),
|
| + globals_->data_reduction_proxy_params->GetDefaultFallbackOrigin());
|
|
|
| net::HttpNetworkSession::Params system_params;
|
| InitializeNetworkSessionParams(&system_params);
|
|
|