| Index: chrome/browser/io_thread.cc
|
| diff --git a/chrome/browser/io_thread.cc b/chrome/browser/io_thread.cc
|
| index 81417197da656000a69cb2079e76256fab4859dd..4f4ccba13b8859187e0cfa50f6533edb28e536b7 100644
|
| --- a/chrome/browser/io_thread.cc
|
| +++ b/chrome/browser/io_thread.cc
|
| @@ -15,6 +15,7 @@
|
| #include "base/string_split.h"
|
| #include "base/string_util.h"
|
| #include "base/threading/thread_restrictions.h"
|
| +#include "chrome/browser/browser_process.h"
|
| #include "chrome/browser/browser_thread.h"
|
| #include "chrome/browser/gpu_process_host.h"
|
| #include "chrome/browser/in_process_webkit/indexed_db_key_utility_client.h"
|
| @@ -195,6 +196,27 @@ ConstructProxyScriptFetcherContext(IOThread::Globals* globals,
|
| return context;
|
| }
|
|
|
| +scoped_refptr<net::URLRequestContext>
|
| +ConstructSystemRequestContext(IOThread::Globals* globals,
|
| + net::NetLog* net_log) {
|
| + scoped_refptr<net::URLRequestContext> context(new net::URLRequestContext);
|
| + context->set_net_log(net_log);
|
| + context->set_host_resolver(globals->host_resolver.get());
|
| + context->set_cert_verifier(globals->cert_verifier.get());
|
| + context->set_dnsrr_resolver(globals->dnsrr_resolver.get());
|
| + context->set_http_auth_handler_factory(
|
| + globals->http_auth_handler_factory.get());
|
| + // TODO(willchan): Use this once a system proxy service gets created.
|
| +#if 0
|
| + context->set_proxy_service(globals->system_proxy_service.get());
|
| +#endif
|
| + context->set_http_transaction_factory(
|
| + globals->system_http_transaction_factory.get());
|
| + // In-memory cookie store.
|
| + context->set_cookie_store(new net::CookieMonster(NULL, NULL));
|
| + return context;
|
| +}
|
| +
|
| } // namespace
|
|
|
| // The IOThread object must outlive any tasks posted to the IO thread before the
|
| @@ -351,6 +373,29 @@ void IOThread::Init() {
|
| scoped_refptr<net::URLRequestContext> proxy_script_fetcher_context =
|
| ConstructProxyScriptFetcherContext(globals_, net_log_);
|
| globals_->proxy_script_fetcher_context = proxy_script_fetcher_context;
|
| +
|
| + // FIXME(willchan): Need to use a real ProxyService. Can't yet because we
|
| + // don't have one that is Profile-agnostic yet.
|
| + globals_->system_proxy_service =
|
| + net::ProxyService::CreateDirectWithNetLog(net_log_);
|
| + globals_->system_http_transaction_factory.reset(
|
| + new net::HttpNetworkLayer(
|
| + globals_->client_socket_factory,
|
| + globals_->host_resolver.get(),
|
| + globals_->cert_verifier.get(),
|
| + globals_->dnsrr_resolver.get(),
|
| + NULL /* dns_cert_checker */,
|
| + NULL /* ssl_host_info_factory */,
|
| + globals_->system_proxy_service,
|
| + globals_->ssl_config_service.get(),
|
| + new net::SpdySessionPool(globals_->ssl_config_service.get()),
|
| + globals_->http_auth_handler_factory.get(),
|
| + &globals_->network_delegate,
|
| + net_log_));
|
| +
|
| + scoped_refptr<net::URLRequestContext> system_request_context =
|
| + ConstructSystemRequestContext(globals_, net_log_);
|
| + globals_->system_request_context = system_request_context;
|
| }
|
|
|
| void IOThread::CleanUp() {
|
|
|