diff options
author | rch@chromium.org <rch@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-08-20 02:04:12 +0000 |
---|---|---|
committer | rch@chromium.org <rch@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-08-20 02:04:12 +0000 |
commit | 11c0587044d54aeef5a7e1e0e2c5fedbe55106cb (patch) | |
tree | a909ed5918e547c77927bfecf66bb11c74df9630 /net/quic/quic_stream_factory.cc | |
parent | 1c494c069af38db45030f88bd8cb81baca39dd84 (diff) | |
download | chromium_src-11c0587044d54aeef5a7e1e0e2c5fedbe55106cb.zip chromium_src-11c0587044d54aeef5a7e1e0e2c5fedbe55106cb.tar.gz chromium_src-11c0587044d54aeef5a7e1e0e2c5fedbe55106cb.tar.bz2 |
Require handshake confirmation until a QUIC connection is created succesfully when using a new network.
BUG=
Review URL: https://chromiumcodereview.appspot.com/23279011
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@218412 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net/quic/quic_stream_factory.cc')
-rw-r--r-- | net/quic/quic_stream_factory.cc | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/net/quic/quic_stream_factory.cc b/net/quic/quic_stream_factory.cc index 892e531..0a16f01 100644 --- a/net/quic/quic_stream_factory.cc +++ b/net/quic/quic_stream_factory.cc @@ -227,6 +227,7 @@ int QuicStreamFactory::Job::DoConnect() { cert_verifier_, address_list_, net_log_); session_->StartReading(); int rv = session_->CryptoConnect( + factory_->require_confirmation(), base::Bind(&QuicStreamFactory::Job::OnIOComplete, base::Unretained(this))); return rv; @@ -249,7 +250,8 @@ QuicStreamFactory::QuicStreamFactory( QuicCryptoClientStreamFactory* quic_crypto_client_stream_factory, QuicRandom* random_generator, QuicClock* clock) - : host_resolver_(host_resolver), + : require_confirmation_(true), + host_resolver_(host_resolver), client_socket_factory_(client_socket_factory), http_server_properties_(http_server_properties), quic_crypto_client_stream_factory_(quic_crypto_client_stream_factory), @@ -304,6 +306,7 @@ int QuicStreamFactory::Create(const HostPortProxyPair& host_port_proxy_pair, void QuicStreamFactory::OnJobComplete(Job* job, int rv) { if (rv == OK) { + require_confirmation_ = false; // Create all the streams, but do not notify them yet. for (RequestSet::iterator it = job_requests_map_[job].begin(); it != job_requests_map_[job].end() ; ++it) { @@ -403,6 +406,7 @@ base::Value* QuicStreamFactory::QuicStreamFactoryInfoToValue() const { void QuicStreamFactory::OnIPAddressChanged() { CloseAllSessions(ERR_NETWORK_CHANGED); + require_confirmation_ = true; } bool QuicStreamFactory::HasActiveSession( |