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 1034 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1045 | 1045 |
1046 globals_->system_http_transaction_factory.reset( | 1046 globals_->system_http_transaction_factory.reset( |
1047 new net::HttpNetworkLayer( | 1047 new net::HttpNetworkLayer( |
1048 new net::HttpNetworkSession(system_params))); | 1048 new net::HttpNetworkSession(system_params))); |
1049 globals_->system_url_request_job_factory.reset( | 1049 globals_->system_url_request_job_factory.reset( |
1050 new net::URLRequestJobFactoryImpl()); | 1050 new net::URLRequestJobFactoryImpl()); |
1051 globals_->system_request_context.reset( | 1051 globals_->system_request_context.reset( |
1052 ConstructSystemRequestContext(globals_, net_log_)); | 1052 ConstructSystemRequestContext(globals_, net_log_)); |
1053 | 1053 |
1054 sdch_manager_->set_sdch_fetcher( | 1054 sdch_manager_->set_sdch_fetcher( |
1055 new SdchDictionaryFetcher(system_url_request_context_getter_.get())); | 1055 new SdchDictionaryFetcher( |
| 1056 sdch_manager_, system_url_request_context_getter_.get())); |
1056 } | 1057 } |
1057 | 1058 |
1058 void IOThread::UpdateDnsClientEnabled() { | 1059 void IOThread::UpdateDnsClientEnabled() { |
1059 globals()->host_resolver->SetDnsClientEnabled(*dns_client_enabled_); | 1060 globals()->host_resolver->SetDnsClientEnabled(*dns_client_enabled_); |
1060 } | 1061 } |
1061 | 1062 |
1062 void IOThread::ConfigureQuic(const CommandLine& command_line) { | 1063 void IOThread::ConfigureQuic(const CommandLine& command_line) { |
1063 // Always fetch the field trial group to ensure it is reported correctly. | 1064 // Always fetch the field trial group to ensure it is reported correctly. |
1064 // The command line flags will be associated with a group that is reported | 1065 // The command line flags will be associated with a group that is reported |
1065 // so long as trial is actually queried. | 1066 // so long as trial is actually queried. |
(...skipping 150 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1216 std::string version_flag = | 1217 std::string version_flag = |
1217 command_line.GetSwitchValueASCII(switches::kQuicVersion); | 1218 command_line.GetSwitchValueASCII(switches::kQuicVersion); |
1218 for (size_t i = 0; i < supported_versions.size(); ++i) { | 1219 for (size_t i = 0; i < supported_versions.size(); ++i) { |
1219 net::QuicVersion version = supported_versions[i]; | 1220 net::QuicVersion version = supported_versions[i]; |
1220 if (net::QuicVersionToString(version) == version_flag) { | 1221 if (net::QuicVersionToString(version) == version_flag) { |
1221 return version; | 1222 return version; |
1222 } | 1223 } |
1223 } | 1224 } |
1224 return net::QUIC_VERSION_UNSUPPORTED; | 1225 return net::QUIC_VERSION_UNSUPPORTED; |
1225 } | 1226 } |
OLD | NEW |