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

Unified Diff: chrome/browser/io_thread.cc

Issue 1922403002: Move bool enable_brotli from HttpNetworkSession::Params (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: unittest fix 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
« no previous file with comments | « chrome/browser/io_thread.h ('k') | chrome/browser/profiles/profile_io_data.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/io_thread.cc
diff --git a/chrome/browser/io_thread.cc b/chrome/browser/io_thread.cc
index 99a914c8229e65878c55c0d0a8716ddabe5f111d..77269f530a068a6c95f5b618829dbaae41ecf36b 100644
--- a/chrome/browser/io_thread.cc
+++ b/chrome/browser/io_thread.cc
@@ -412,7 +412,8 @@ SystemRequestContextLeakChecker::~SystemRequestContextLeakChecker() {
globals_->system_request_context->AssertNoURLRequests();
}
-IOThread::Globals::Globals() : system_request_context_leak_checker(this) {}
+IOThread::Globals::Globals() : system_request_context_leak_checker(this),
+ enable_brotli(false) {}
IOThread::Globals::~Globals() {}
@@ -802,7 +803,7 @@ void IOThread::Init() {
switches::kEnableUserAlternateProtocolPorts)) {
params_.enable_user_alternate_protocol_ports = true;
}
- params_.enable_brotli =
+ globals_->enable_brotli =
base::FeatureList::IsEnabled(features::kBrotliEncoding);
params_.enable_token_binding =
base::FeatureList::IsEnabled(features::kTokenBinding);
@@ -1677,6 +1678,8 @@ net::URLRequestContext* IOThread::ConstructSystemRequestContext(
context->set_http_server_properties(
globals->http_server_properties->GetWeakPtr());
+ context->set_enable_brotli(globals->enable_brotli);
+
net::HttpNetworkSession::Params system_params(params);
net::URLRequestContextBuilder::SetHttpNetworkSessionComponents(
context, &system_params);
@@ -1726,6 +1729,8 @@ net::URLRequestContext* IOThread::ConstructProxyScriptFetcherContext(
context->set_http_server_properties(
globals->http_server_properties->GetWeakPtr());
+ context->set_enable_brotli(globals->enable_brotli);
+
net::HttpNetworkSession::Params session_params(params);
net::URLRequestContextBuilder::SetHttpNetworkSessionComponents(
context, &session_params);
« no previous file with comments | « chrome/browser/io_thread.h ('k') | chrome/browser/profiles/profile_io_data.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698