Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(418)

Unified Diff: components/cronet/ios/cronet_environment.cc

Issue 1888963004: Add HttpProtocolHandler and convert everything to use it (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@remove-supports-scheme
Patch Set: even more rebase Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: components/cronet/ios/cronet_environment.cc
diff --git a/components/cronet/ios/cronet_environment.cc b/components/cronet/ios/cronet_environment.cc
index 00c1fd513373ce48095c3d97b7831bbd594603a1..2f4bcd7fc456c18d0960abdf73bdc2b0e99a04b4 100644
--- a/components/cronet/ios/cronet_environment.cc
+++ b/components/cronet/ios/cronet_environment.cc
@@ -352,9 +352,9 @@ void CronetEnvironment::InitializeOnNetworkThread() {
true /* set_up_quic_server_info */);
main_context_->set_http_transaction_factory(main_cache);
- net::URLRequestJobFactoryImpl* job_factory =
- new net::URLRequestJobFactoryImpl;
- main_context_->set_job_factory(job_factory);
+ std::unique_ptr<net::URLRequestJobFactoryImpl> job_factory =
+ net::URLRequestJobFactoryImpl::CreateWithDefaultProtocolHandlers();
mmenke 2016/04/22 18:37:52 Could you add a TODO about fixing this leak?
mgersh 2016/04/22 20:27:15 This function, and the crnet equivalent, already h
mmenke 2016/04/22 20:41:04 I'd say yes, just to make it clearer that this is
mgersh 2016/04/27 16:13:52 Done.
+ main_context_->set_job_factory(job_factory.release());
main_context_->set_net_log(net_log_.get());
}

Powered by Google App Engine
This is Rietveld 408576698