diff options
Diffstat (limited to 'net')
-rw-r--r-- | net/socket/client_socket_pool_base.cc | 9 | ||||
-rw-r--r-- | net/socket/client_socket_pool_base.h | 8 | ||||
-rw-r--r-- | net/socket/transport_client_socket_pool.cc | 2 |
3 files changed, 0 insertions, 19 deletions
diff --git a/net/socket/client_socket_pool_base.cc b/net/socket/client_socket_pool_base.cc index 0972534..ddcbba6 100644 --- a/net/socket/client_socket_pool_base.cc +++ b/net/socket/client_socket_pool_base.cc @@ -45,7 +45,6 @@ ConnectJob::ConnectJob(const std::string& group_name, delegate_(delegate), net_log_(net_log), idle_(true), - prefer_ipv4_(false), preconnect_state_(NOT_PRECONNECT) { DCHECK(!group_name.empty()); DCHECK(delegate); @@ -1071,14 +1070,6 @@ void ClientSocketPoolBaseHelper::Group::OnBackupSocketTimerFired( group_name, **pending_requests_.begin(), pool); backup_job->net_log().AddEvent(NetLog::TYPE_SOCKET_BACKUP_CREATED, NULL); SIMPLE_STATS_COUNTER("socket.backup_created"); - // The purpose of the backup job is to initiate a new connect job when the - // first connect job takes too long. We call set_prefer_ipv4 here to use - // the backup job for a second purpose: if the first connect job is IPv6, - // try an IPv4 connect job in parallel. This hides the long timeout error - // on some networks with broken IPv6 support. - // TODO(wtc): remove the set_prefer_ipv4 call when broken IPv6 networks are - // gone. - backup_job->set_prefer_ipv4(); int rv = backup_job->Connect(); pool->connecting_socket_count_++; AddJob(backup_job); diff --git a/net/socket/client_socket_pool_base.h b/net/socket/client_socket_pool_base.h index 25bc7c7..318cab8 100644 --- a/net/socket/client_socket_pool_base.h +++ b/net/socket/client_socket_pool_base.h @@ -80,7 +80,6 @@ class ConnectJob { bool is_unused_preconnect() const { return preconnect_state_ == UNUSED_PRECONNECT; } - bool prefer_ipv4() const { return prefer_ipv4_; } // Initialized by the ClientSocketPoolBaseHelper. // TODO(willchan): Move most of the constructor arguments over here. We @@ -88,11 +87,6 @@ class ConnectJob { // the initialization. void Initialize(bool is_preconnect); - // Instructs the ConnectJob to try IPv4 addresses first. This can be useful - // when IPv6 is likely to be broken. - // TODO(wtc): this should be folded into the Initialize() method. - void set_prefer_ipv4() { prefer_ipv4_ = true; } - // Releases |socket_| to the client. On connection error, this should return // NULL. StreamSocket* ReleaseSocket() { return socket_.release(); } @@ -148,8 +142,6 @@ class ConnectJob { BoundNetLog net_log_; // A ConnectJob is idle until Connect() has been called. bool idle_; - // True if we should try IPv4 addresses first. - bool prefer_ipv4_; PreconnectState preconnect_state_; DISALLOW_COPY_AND_ASSIGN(ConnectJob); diff --git a/net/socket/transport_client_socket_pool.cc b/net/socket/transport_client_socket_pool.cc index 66b4ec9..c35a934 100644 --- a/net/socket/transport_client_socket_pool.cc +++ b/net/socket/transport_client_socket_pool.cc @@ -175,8 +175,6 @@ int TransportConnectJob::DoResolveHostComplete(int result) { int TransportConnectJob::DoTransportConnect() { next_state_ = STATE_TRANSPORT_CONNECT_COMPLETE; - if (prefer_ipv4()) - MakeAddrListStartWithIPv4(&addresses_); set_socket(client_socket_factory_->CreateTransportClientSocket( addresses_, net_log().net_log(), net_log().source())); connect_start_time_ = base::TimeTicks::Now(); |