OLD | NEW |
---|---|
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "android_webview/browser/net/aw_url_request_context_getter.h" | 5 #include "android_webview/browser/net/aw_url_request_context_getter.h" |
6 | 6 |
7 #include <vector> | 7 #include <vector> |
8 | 8 |
9 #include "android_webview/browser/aw_browser_context.h" | 9 #include "android_webview/browser/aw_browser_context.h" |
10 #include "android_webview/browser/aw_content_browser_client.h" | 10 #include "android_webview/browser/aw_content_browser_client.h" |
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
71 if (command_line.HasSwitch(switches::kTestingFixedHttpPort)) { | 71 if (command_line.HasSwitch(switches::kTestingFixedHttpPort)) { |
72 base::StringToInt(command_line.GetSwitchValueASCII( | 72 base::StringToInt(command_line.GetSwitchValueASCII( |
73 switches::kTestingFixedHttpPort), &value); | 73 switches::kTestingFixedHttpPort), &value); |
74 params->testing_fixed_http_port = value; | 74 params->testing_fixed_http_port = value; |
75 } | 75 } |
76 if (command_line.HasSwitch(switches::kTestingFixedHttpsPort)) { | 76 if (command_line.HasSwitch(switches::kTestingFixedHttpsPort)) { |
77 base::StringToInt(command_line.GetSwitchValueASCII( | 77 base::StringToInt(command_line.GetSwitchValueASCII( |
78 switches::kTestingFixedHttpsPort), &value); | 78 switches::kTestingFixedHttpsPort), &value); |
79 params->testing_fixed_https_port = value; | 79 params->testing_fixed_https_port = value; |
80 } | 80 } |
81 if (command_line.HasSwitch(switches::kIgnoreCertificateErrors)) { | |
82 params->ignore_certificate_errors = true; | |
83 } else { | |
84 params->ignore_certificate_errors = false; | |
sgurun-gerrit only
2014/07/29 22:21:18
default is false, so no need to do it (and it seem
| |
85 } | |
81 } | 86 } |
82 | 87 |
83 void PopulateNetworkSessionParams( | 88 void PopulateNetworkSessionParams( |
84 net::URLRequestContext* context, | 89 net::URLRequestContext* context, |
85 net::HttpNetworkSession::Params* params) { | 90 net::HttpNetworkSession::Params* params) { |
86 params->host_resolver = context->host_resolver(); | 91 params->host_resolver = context->host_resolver(); |
87 params->cert_verifier = context->cert_verifier(); | 92 params->cert_verifier = context->cert_verifier(); |
88 params->channel_id_service = context->channel_id_service(); | 93 params->channel_id_service = context->channel_id_service(); |
89 params->transport_security_state = context->transport_security_state(); | 94 params->transport_security_state = context->transport_security_state(); |
90 params->proxy_service = context->proxy_service(); | 95 params->proxy_service = context->proxy_service(); |
(...skipping 170 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
261 request_interceptors_.swap(request_interceptors); | 266 request_interceptors_.swap(request_interceptors); |
262 } | 267 } |
263 | 268 |
264 DataReductionProxyConfigService* | 269 DataReductionProxyConfigService* |
265 AwURLRequestContextGetter::proxy_config_service() { | 270 AwURLRequestContextGetter::proxy_config_service() { |
266 // TODO(bengr): return system config if data reduction proxy is disabled. | 271 // TODO(bengr): return system config if data reduction proxy is disabled. |
267 return proxy_config_service_.get(); | 272 return proxy_config_service_.get(); |
268 } | 273 } |
269 | 274 |
270 } // namespace android_webview | 275 } // namespace android_webview |
OLD | NEW |