fix: create system network context for global requests

Global requests currently includes DNS over HTTPS requests,
certain cert validation requests (OCSP, AIA, etc) on some platforms
and geolocation requests.
This commit is contained in:
deepak1556 2018-11-06 11:40:04 +05:30
parent 787dbbe610
commit 414dcfcd07
8 changed files with 448 additions and 86 deletions

View file

@ -348,6 +348,9 @@ void AtomBrowserMainParts::PostEarlyInitialization() {
// command-line changes.
base::FeatureList::ClearInstanceForTesting();
InitializeFeatureList();
// Initialize after user script environment creation.
fake_browser_process_->PostEarlyInitialization();
}
int AtomBrowserMainParts::PreCreateThreads() {
@ -394,6 +397,7 @@ int AtomBrowserMainParts::PreCreateThreads() {
// Initialize net log file exporter.
net_log_->net_export_file_writer()->Initialize();
fake_browser_process_->PreCreateThreads(command_line);
// Manage global state of net and other IO thread related.
io_thread_ = std::make_unique<IOThread>(net_log_.get());
@ -523,6 +527,8 @@ void AtomBrowserMainParts::PostMainMessageLoopRun() {
std::move(callback).Run();
++iter;
}
fake_browser_process_->PostMainMessageLoopRun();
}
#if !defined(OS_MACOSX)