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

Unified Diff: net/socket/client_socket_pool_base.cc

Issue 1120007: Disable backup connect jobs for all pools except TCPClientSocketPool (Closed)
Patch Set: Created 10 years, 9 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 | « net/socket/client_socket_pool_base.h ('k') | net/socket/client_socket_pool_base_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/socket/client_socket_pool_base.cc
diff --git a/net/socket/client_socket_pool_base.cc b/net/socket/client_socket_pool_base.cc
index 3e32cc1f73c85c27d49ee440c5c7a4d836f1e385..d567743c5fbcd16abf5a0dfa8e56043ffac8bae9 100644
--- a/net/socket/client_socket_pool_base.cc
+++ b/net/socket/client_socket_pool_base.cc
@@ -116,6 +116,7 @@ ClientSocketPoolBaseHelper::ClientSocketPoolBaseHelper(
may_have_stalled_group_(false),
connect_job_factory_(connect_job_factory),
network_change_notifier_(network_change_notifier),
+ backup_jobs_enabled_(false),
ALLOW_THIS_IN_INITIALIZER_LIST(method_factory_(this)) {
DCHECK_LE(0, max_sockets_per_group);
DCHECK_LE(max_sockets_per_group, max_sockets);
@@ -243,7 +244,7 @@ int ClientSocketPoolBaseHelper::RequestSocketInternal(
// If we don't have any sockets in this group, set a timer for potentially
// creating a new one. If the SYN is lost, this backup socket may complete
// before the slow socket, improving end user latency.
- if (group.IsEmpty() && !group.backup_job) {
+ if (group.IsEmpty() && !group.backup_job && backup_jobs_enabled_) {
group.backup_job = connect_job_factory_->NewConnectJob(group_name,
*request,
this,
« no previous file with comments | « net/socket/client_socket_pool_base.h ('k') | net/socket/client_socket_pool_base_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698