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 8ac61f10b528de01cfe9e4fbac37474cdf8412af..d46b0974e60e99a5bfe63589c2b6d2383e5bd7e0 100644 |
--- a/chrome/browser/profiles/off_the_record_profile_io_data.cc |
+++ b/chrome/browser/profiles/off_the_record_profile_io_data.cc |
@@ -253,8 +253,8 @@ void OffTheRecordProfileIOData::InitializeInternal( |
new net::FtpNetworkLayer(main_context->host_resolver())); |
#endif // !defined(DISABLE_FTP_SUPPORT) |
- std::unique_ptr<net::URLRequestJobFactoryImpl> main_job_factory( |
- new net::URLRequestJobFactoryImpl()); |
+ std::unique_ptr<net::URLRequestJobFactoryImpl> main_job_factory = |
+ net::URLRequestJobFactoryImpl::CreateWithDefaultProtocolHandlers(); |
InstallProtocolHandlers(main_job_factory.get(), protocol_handlers); |
main_job_factory_ = SetUpJobFactoryDefaults( |
@@ -299,8 +299,8 @@ void OffTheRecordProfileIOData:: |
extensions_cookie_store_ = content::CreateCookieStore(cookie_config); |
extensions_context->set_cookie_store(extensions_cookie_store_.get()); |
- std::unique_ptr<net::URLRequestJobFactoryImpl> extensions_job_factory( |
- new net::URLRequestJobFactoryImpl()); |
+ std::unique_ptr<net::URLRequestJobFactoryImpl> extensions_job_factory = |
+ net::URLRequestJobFactoryImpl::CreateWithDefaultProtocolHandlers(); |
// TODO(shalev): The extensions_job_factory has a NULL NetworkDelegate. |
// Without a network_delegate, this protocol handler will never |
// handle file: requests, but as a side effect it makes |
@@ -339,8 +339,8 @@ net::URLRequestContext* OffTheRecordProfileIOData::InitializeAppRequestContext( |
context->SetHttpTransactionFactory(std::move(app_http_cache)); |
- std::unique_ptr<net::URLRequestJobFactoryImpl> job_factory( |
- new net::URLRequestJobFactoryImpl()); |
+ std::unique_ptr<net::URLRequestJobFactoryImpl> job_factory = |
+ net::URLRequestJobFactoryImpl::CreateWithDefaultProtocolHandlers(); |
InstallProtocolHandlers(job_factory.get(), protocol_handlers); |
std::unique_ptr<net::URLRequestJobFactory> top_job_factory; |
top_job_factory = SetUpJobFactoryDefaults( |