Index: chrome/browser/profiles/off_the_record_profile_io_data.cc |
diff --git a/chrome/browser/profiles/off_the_record_profile_io_data.cc b/chrome/browser/profiles/off_the_record_profile_io_data.cc |
index b13a701e714297d12bc3dd77bfc2a41fea7af118..705e7352bcbf9c21e6d9029f4d8773ecb2977bd1 100644 |
--- a/chrome/browser/profiles/off_the_record_profile_io_data.cc |
+++ b/chrome/browser/profiles/off_the_record_profile_io_data.cc |
@@ -196,9 +196,11 @@ OffTheRecordProfileIOData::~OffTheRecordProfileIOData() { |
} |
void OffTheRecordProfileIOData::InitializeInternal( |
+ scoped_ptr<ChromeNetworkDelegate> chrome_network_delegate, |
ProfileParams* profile_params, |
content::ProtocolHandlerMap* protocol_handlers, |
content::URLRequestInterceptorScopedVector request_interceptors) const { |
+ |
mmenke
2014/12/04 20:50:56
nit: Remove blank line
megjablon
2014/12/05 22:24:20
Done.
|
net::URLRequestContext* main_context = main_request_context(); |
IOThread* const io_thread = profile_params->io_thread; |
@@ -210,7 +212,9 @@ void OffTheRecordProfileIOData::InitializeInternal( |
main_context->set_net_log(io_thread->net_log()); |
- main_context->set_network_delegate(network_delegate()); |
+ main_context->set_network_delegate(chrome_network_delegate.get()); |
+ |
+ network_delegate_ = chrome_network_delegate.Pass(); |
main_context->set_host_resolver( |
io_thread_globals->host_resolver.get()); |
@@ -266,7 +270,7 @@ void OffTheRecordProfileIOData::InitializeInternal( |
main_job_factory.Pass(), |
request_interceptors.Pass(), |
profile_params->protocol_handler_interceptor.Pass(), |
- network_delegate(), |
+ main_context->network_delegate(), |
ftp_factory_.get()); |
main_context->set_job_factory(main_job_factory_.get()); |
@@ -364,7 +368,7 @@ net::URLRequestContext* OffTheRecordProfileIOData::InitializeAppRequestContext( |
top_job_factory = SetUpJobFactoryDefaults(job_factory.Pass(), |
request_interceptors.Pass(), |
protocol_handler_interceptor.Pass(), |
- network_delegate(), |
+ main_context->network_delegate(), |
ftp_factory_.get()); |
context->SetJobFactory(top_job_factory.Pass()); |
return context; |