Index: chrome/browser/io_thread.cc |
diff --git a/chrome/browser/io_thread.cc b/chrome/browser/io_thread.cc |
index ac24cd6912b3a713943af2960c79113cd1874e16..5db85a83e9351db5f996c00880178f3d797586ab 100644 |
--- a/chrome/browser/io_thread.cc |
+++ b/chrome/browser/io_thread.cc |
@@ -70,6 +70,7 @@ |
#include "net/http/http_auth_filter.h" |
#include "net/http/http_auth_handler_factory.h" |
#include "net/http/http_network_layer.h" |
+#include "net/http/http_network_session.h" |
#include "net/http/http_server_properties_impl.h" |
#include "net/proxy/proxy_config_service.h" |
#include "net/proxy/proxy_script_fetcher_impl.h" |
@@ -1500,8 +1501,10 @@ net::URLRequestContext* IOThread::ConstructSystemRequestContext( |
net::URLRequestContextBuilder::SetHttpNetworkSessionComponents( |
context, &system_params); |
+ globals->system_http_network_session.reset( |
+ new net::HttpNetworkSession(system_params)); |
globals->system_http_transaction_factory.reset( |
- new net::HttpNetworkLayer(new net::HttpNetworkSession(system_params))); |
+ new net::HttpNetworkLayer(globals->system_http_network_session.get())); |
context->set_http_transaction_factory( |
globals->system_http_transaction_factory.get()); |
@@ -1551,15 +1554,16 @@ net::URLRequestContext* IOThread::ConstructProxyScriptFetcherContext( |
tracked_objects::ScopedTracker tracking_profile2( |
FROM_HERE_WITH_EXPLICIT_FUNCTION( |
"466432 IOThread::ConstructProxyScriptFetcherContext2")); |
- scoped_refptr<net::HttpNetworkSession> network_session( |
+ globals->proxy_script_fetcher_http_network_session.reset( |
new net::HttpNetworkSession(session_params)); |
// TODO(erikchen): Remove ScopedTracker below once http://crbug.com/466432 |
// is fixed. |
tracked_objects::ScopedTracker tracking_profile3( |
FROM_HERE_WITH_EXPLICIT_FUNCTION( |
"466432 IOThread::ConstructProxyScriptFetcherContext3")); |
- globals->proxy_script_fetcher_http_transaction_factory |
- .reset(new net::HttpNetworkLayer(network_session.get())); |
+ globals->proxy_script_fetcher_http_transaction_factory.reset( |
+ new net::HttpNetworkLayer( |
+ globals->proxy_script_fetcher_http_network_session.get())); |
context->set_http_transaction_factory( |
globals->proxy_script_fetcher_http_transaction_factory.get()); |