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 "chrome/browser/io_thread.h" | 5 #include "chrome/browser/io_thread.h" |
6 | 6 |
7 #include <vector> | 7 #include <vector> |
8 | 8 |
9 #include "base/base64.h" | 9 #include "base/base64.h" |
10 #include "base/bind.h" | 10 #include "base/bind.h" |
(...skipping 1200 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1211 void IOThread::InitSystemRequestContextOnIOThread() { | 1211 void IOThread::InitSystemRequestContextOnIOThread() { |
1212 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); | 1212 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); |
1213 DCHECK(!globals_->system_proxy_service.get()); | 1213 DCHECK(!globals_->system_proxy_service.get()); |
1214 DCHECK(system_proxy_config_service_.get()); | 1214 DCHECK(system_proxy_config_service_.get()); |
1215 | 1215 |
1216 const base::CommandLine& command_line = | 1216 const base::CommandLine& command_line = |
1217 *base::CommandLine::ForCurrentProcess(); | 1217 *base::CommandLine::ForCurrentProcess(); |
1218 globals_->system_proxy_service = ProxyServiceFactory::CreateProxyService( | 1218 globals_->system_proxy_service = ProxyServiceFactory::CreateProxyService( |
1219 net_log_, globals_->proxy_script_fetcher_context.get(), | 1219 net_log_, globals_->proxy_script_fetcher_context.get(), |
1220 globals_->system_network_delegate.get(), | 1220 globals_->system_network_delegate.get(), |
1221 system_proxy_config_service_.release(), command_line, | 1221 system_proxy_config_service_.Pass(), command_line, |
1222 quick_check_enabled_.GetValue()); | 1222 quick_check_enabled_.GetValue()); |
1223 | 1223 |
1224 net::HttpNetworkSession::Params system_params; | 1224 net::HttpNetworkSession::Params system_params; |
1225 InitializeNetworkSessionParams(&system_params); | 1225 InitializeNetworkSessionParams(&system_params); |
1226 system_params.net_log = net_log_; | 1226 system_params.net_log = net_log_; |
1227 system_params.proxy_service = globals_->system_proxy_service.get(); | 1227 system_params.proxy_service = globals_->system_proxy_service.get(); |
1228 | 1228 |
1229 globals_->system_http_transaction_factory.reset( | 1229 globals_->system_http_transaction_factory.reset( |
1230 new net::HttpNetworkLayer( | 1230 new net::HttpNetworkLayer( |
1231 new net::HttpNetworkSession(system_params))); | 1231 new net::HttpNetworkSession(system_params))); |
(...skipping 361 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1593 net::QuicVersionVector supported_versions = net::QuicSupportedVersions(); | 1593 net::QuicVersionVector supported_versions = net::QuicSupportedVersions(); |
1594 for (size_t i = 0; i < supported_versions.size(); ++i) { | 1594 for (size_t i = 0; i < supported_versions.size(); ++i) { |
1595 net::QuicVersion version = supported_versions[i]; | 1595 net::QuicVersion version = supported_versions[i]; |
1596 if (net::QuicVersionToString(version) == quic_version) { | 1596 if (net::QuicVersionToString(version) == quic_version) { |
1597 return version; | 1597 return version; |
1598 } | 1598 } |
1599 } | 1599 } |
1600 | 1600 |
1601 return net::QUIC_VERSION_UNSUPPORTED; | 1601 return net::QUIC_VERSION_UNSUPPORTED; |
1602 } | 1602 } |
OLD | NEW |