Chromium Code Reviews| 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 "net/socket/client_socket_pool_manager.h" | 5 #include "net/socket/client_socket_pool_manager.h" |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 | 8 |
| 9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
| 10 #include "base/logging.h" | 10 #include "base/logging.h" |
| (...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 86 const CompletionCallback& callback) { | 86 const CompletionCallback& callback) { |
| 87 scoped_refptr<HttpProxySocketParams> http_proxy_params; | 87 scoped_refptr<HttpProxySocketParams> http_proxy_params; |
| 88 scoped_refptr<SOCKSSocketParams> socks_params; | 88 scoped_refptr<SOCKSSocketParams> socks_params; |
| 89 scoped_ptr<HostPortPair> proxy_host_port; | 89 scoped_ptr<HostPortPair> proxy_host_port; |
| 90 | 90 |
| 91 bool using_ssl = request_url.SchemeIs("https") || | 91 bool using_ssl = request_url.SchemeIs("https") || |
| 92 request_url.SchemeIs("wss") || force_spdy_over_ssl; | 92 request_url.SchemeIs("wss") || force_spdy_over_ssl; |
| 93 | 93 |
| 94 HostPortPair origin_host_port = | 94 HostPortPair origin_host_port = |
| 95 HostPortPair(request_url.HostNoBrackets(), | 95 HostPortPair(request_url.HostNoBrackets(), |
| 96 request_url.EffectiveIntPort()); | 96 static_cast<uint16>(request_url.EffectiveIntPort())); |
|
mmenke
2014/11/18 21:06:39
HostPortPair::FromURL
Peter Kasting
2014/11/18 23:38:42
Done.
| |
| 97 | 97 |
| 98 if (!using_ssl && session->params().testing_fixed_http_port != 0) { | 98 if (!using_ssl && session->params().testing_fixed_http_port != 0) { |
| 99 origin_host_port.set_port(session->params().testing_fixed_http_port); | 99 origin_host_port.set_port(session->params().testing_fixed_http_port); |
| 100 } else if (using_ssl && session->params().testing_fixed_https_port != 0) { | 100 } else if (using_ssl && session->params().testing_fixed_https_port != 0) { |
| 101 origin_host_port.set_port(session->params().testing_fixed_https_port); | 101 origin_host_port.set_port(session->params().testing_fixed_https_port); |
| 102 } | 102 } |
| 103 | 103 |
| 104 bool disable_resolver_cache = | 104 bool disable_resolver_cache = |
| 105 request_load_flags & LOAD_BYPASS_CACHE || | 105 request_load_flags & LOAD_BYPASS_CACHE || |
| 106 request_load_flags & LOAD_VALIDATE_CACHE || | 106 request_load_flags & LOAD_VALIDATE_CACHE || |
| (...skipping 400 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 507 int num_preconnect_streams) { | 507 int num_preconnect_streams) { |
| 508 return InitSocketPoolHelper( | 508 return InitSocketPoolHelper( |
| 509 request_url, request_extra_headers, request_load_flags, request_priority, | 509 request_url, request_extra_headers, request_load_flags, request_priority, |
| 510 session, proxy_info, force_spdy_over_ssl, want_spdy_over_npn, | 510 session, proxy_info, force_spdy_over_ssl, want_spdy_over_npn, |
| 511 ssl_config_for_origin, ssl_config_for_proxy, false, privacy_mode, net_log, | 511 ssl_config_for_origin, ssl_config_for_proxy, false, privacy_mode, net_log, |
| 512 num_preconnect_streams, NULL, HttpNetworkSession::NORMAL_SOCKET_POOL, | 512 num_preconnect_streams, NULL, HttpNetworkSession::NORMAL_SOCKET_POOL, |
| 513 OnHostResolutionCallback(), CompletionCallback()); | 513 OnHostResolutionCallback(), CompletionCallback()); |
| 514 } | 514 } |
| 515 | 515 |
| 516 } // namespace net | 516 } // namespace net |
| OLD | NEW |