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

Unified Diff: net/quic/test_tools/mock_crypto_client_stream.cc

Issue 23279011: Require handshake confirmation until a QUIC connection is created succesfully when using a new netw… (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix Created 7 years, 4 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
Index: net/quic/test_tools/mock_crypto_client_stream.cc
diff --git a/net/quic/test_tools/mock_crypto_client_stream.cc b/net/quic/test_tools/mock_crypto_client_stream.cc
index 79c335317144862d20d68bd646a8b7f84d7cb835..bfeb06f06292d450b6e52133dac61be187a183d6 100644
--- a/net/quic/test_tools/mock_crypto_client_stream.cc
+++ b/net/quic/test_tools/mock_crypto_client_stream.cc
@@ -51,6 +51,16 @@ bool MockCryptoClientStream::CryptoConnect() {
return true;
}
+void MockCryptoClientStream::SendOnCryptoHandshakeEvent(
+ QuicSession::CryptoHandshakeEvent event) {
+ encryption_established_ = true;
wtc 2013/08/21 01:09:32 Nit: it seems that we only need to set encryption_
+ if (event == QuicSession::HANDSHAKE_CONFIRMED) {
+ handshake_confirmed_ = true;
+ SetConfigNegotiated();
+ }
+ session()->OnCryptoHandshakeEvent(event);
+}
+
void MockCryptoClientStream::SetConfigNegotiated() {
ASSERT_FALSE(session()->config()->negotiated());
QuicTagVector cgst;

Powered by Google App Engine
This is Rietveld 408576698