Index: net/quic/quic_crypto_client_stream.cc |
diff --git a/net/quic/quic_crypto_client_stream.cc b/net/quic/quic_crypto_client_stream.cc |
index fd5422eaa792dce79201fe71dad566e5afc6f2e4..71d369d7607fe8cf5bb6d1802bede2ed4329aa80 100644 |
--- a/net/quic/quic_crypto_client_stream.cc |
+++ b/net/quic/quic_crypto_client_stream.cc |
@@ -427,10 +427,11 @@ int QuicCryptoClientStream::DoLoadQuicServerInfo( |
// TODO(rtenneti): If multiple tabs load the same URL, all requests except for |
// the first request send InchoateClientHello. Fix the code to handle multiple |
// requests. A possible solution is to wait for the first request to finish |
- // and use the data from the disk cache for all requests. |
- // quic_server_info->Persist requires quic_server_info to be ready. We might |
- // have already initialized |cached| config from a the cached state for a |
- // canonical hostname. |
+ // and use the data from the disk cache for all requests. We may need to call |
wtc
2014/02/21 00:04:28
Please start a new paragraph, to make it clear tha
ramant (doing other things)
2014/02/21 00:08:10
Thanks very much.
Done.
|
+ // quic_server_info->Persist later. quic_server_info->Persist requires |
+ // quic_server_info to be ready, so we always call WaitForDataReady, even |
+ // though we might have initialized |cached| config from the cached state for |
+ // a canonical hostname. |
int rv = quic_server_info->WaitForDataReady( |
base::Bind(&QuicCryptoClientStream::OnIOComplete, |
base::Unretained(this))); |
@@ -447,11 +448,8 @@ void QuicCryptoClientStream::DoLoadQuicServerInfoComplete( |
// If someone else already saved a server config, we don't want to overwrite |
// it. Also, if someone else saved a server config and then cleared it (so |
- // cached->IsEmpty() is true, but the generation counter changed), we still |
- // want to load from QuicServerInfo. |
+ // cached->IsEmpty() is true), we still want to load from QuicServerInfo. |
if (!cached->IsEmpty()) { |
- // Someone else has already saved a server config received from the network |
- // or the canonical server config. |
return; |
} |