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

Side by Side Diff: ios/chrome/browser/ios_chrome_io_thread.mm

Issue 2079283002: [iOS/GN] Allow compilation with system clang. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rename use_system_clang to is_clang_xcode Created 4 years, 6 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 unified diff | Download patch
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "ios/chrome/browser/ios_chrome_io_thread.h" 5 #include "ios/chrome/browser/ios_chrome_io_thread.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <utility> 9 #include <utility>
10 #include <vector> 10 #include <vector>
(...skipping 341 matching lines...) Expand 10 before | Expand all | Expand 10 after
352 globals_->transport_security_state.reset(new net::TransportSecurityState()); 352 globals_->transport_security_state.reset(new net::TransportSecurityState());
353 353
354 std::vector<scoped_refptr<const net::CTLogVerifier>> ct_logs( 354 std::vector<scoped_refptr<const net::CTLogVerifier>> ct_logs(
355 net::ct::CreateLogVerifiersForKnownLogs()); 355 net::ct::CreateLogVerifiersForKnownLogs());
356 356
357 net::MultiLogCTVerifier* ct_verifier = new net::MultiLogCTVerifier(); 357 net::MultiLogCTVerifier* ct_verifier = new net::MultiLogCTVerifier();
358 globals_->cert_transparency_verifier.reset(ct_verifier); 358 globals_->cert_transparency_verifier.reset(ct_verifier);
359 // Add built-in logs 359 // Add built-in logs
360 ct_verifier->AddLogs(ct_logs); 360 ct_verifier->AddLogs(ct_logs);
361 361
362 params_.ct_policy_enforcer = new net::CTPolicyEnforcer; 362 globals_->ct_policy_enforcer.reset(new net::CTPolicyEnforcer());
363 363
364 globals_->ssl_config_service = GetSSLConfigService(); 364 globals_->ssl_config_service = GetSSLConfigService();
365 365
366 CreateDefaultAuthHandlerFactory(); 366 CreateDefaultAuthHandlerFactory();
367 globals_->http_server_properties.reset(new net::HttpServerPropertiesImpl()); 367 globals_->http_server_properties.reset(new net::HttpServerPropertiesImpl());
368 // In-memory cookie store. 368 // In-memory cookie store.
369 globals_->system_cookie_store.reset(new net::CookieMonster(nullptr, nullptr)); 369 globals_->system_cookie_store.reset(new net::CookieMonster(nullptr, nullptr));
370 // In-memory channel ID store. 370 // In-memory channel ID store.
371 globals_->system_channel_id_service.reset( 371 globals_->system_channel_id_service.reset(
372 new net::ChannelIDService(new net::DefaultChannelIDStore(nullptr), 372 new net::ChannelIDService(new net::DefaultChannelIDStore(nullptr),
(...skipping 150 matching lines...) Expand 10 before | Expand all | Expand 10 after
523 context->set_host_resolver(globals->host_resolver.get()); 523 context->set_host_resolver(globals->host_resolver.get());
524 context->set_cert_verifier(globals->cert_verifier.get()); 524 context->set_cert_verifier(globals->cert_verifier.get());
525 context->set_transport_security_state( 525 context->set_transport_security_state(
526 globals->transport_security_state.get()); 526 globals->transport_security_state.get());
527 context->set_cert_transparency_verifier( 527 context->set_cert_transparency_verifier(
528 globals->cert_transparency_verifier.get()); 528 globals->cert_transparency_verifier.get());
529 context->set_ssl_config_service(globals->ssl_config_service.get()); 529 context->set_ssl_config_service(globals->ssl_config_service.get());
530 context->set_http_auth_handler_factory( 530 context->set_http_auth_handler_factory(
531 globals->http_auth_handler_factory.get()); 531 globals->http_auth_handler_factory.get());
532 context->set_proxy_service(globals->system_proxy_service.get()); 532 context->set_proxy_service(globals->system_proxy_service.get());
533 context->set_ct_policy_enforcer(globals->ct_policy_enforcer.get());
533 534
534 net::URLRequestJobFactoryImpl* system_job_factory = 535 net::URLRequestJobFactoryImpl* system_job_factory =
535 new net::URLRequestJobFactoryImpl(); 536 new net::URLRequestJobFactoryImpl();
536 // Data URLs are always loaded through the system request context on iOS 537 // Data URLs are always loaded through the system request context on iOS
537 // (due to UIWebView limitations). 538 // (due to UIWebView limitations).
538 bool set_protocol = system_job_factory->SetProtocolHandler( 539 bool set_protocol = system_job_factory->SetProtocolHandler(
539 url::kDataScheme, base::WrapUnique(new net::DataProtocolHandler())); 540 url::kDataScheme, base::WrapUnique(new net::DataProtocolHandler()));
540 DCHECK(set_protocol); 541 DCHECK(set_protocol);
541 globals->system_url_request_job_factory.reset(system_job_factory); 542 globals->system_url_request_job_factory.reset(system_job_factory);
542 context->set_job_factory(globals->system_url_request_job_factory.get()); 543 context->set_job_factory(globals->system_url_request_job_factory.get());
(...skipping 15 matching lines...) Expand all
558 559
559 globals->system_http_network_session.reset( 560 globals->system_http_network_session.reset(
560 new net::HttpNetworkSession(system_params)); 561 new net::HttpNetworkSession(system_params));
561 globals->system_http_transaction_factory.reset( 562 globals->system_http_transaction_factory.reset(
562 new net::HttpNetworkLayer(globals->system_http_network_session.get())); 563 new net::HttpNetworkLayer(globals->system_http_network_session.get()));
563 context->set_http_transaction_factory( 564 context->set_http_transaction_factory(
564 globals->system_http_transaction_factory.get()); 565 globals->system_http_transaction_factory.get());
565 566
566 return context; 567 return context;
567 } 568 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698