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

Unified Diff: net/tools/quic/quic_client_base.cc

Issue 2547583002: Landing Recent QUIC changes until Fri Nov 18 23:21:04 2016 +0000 (Closed)
Patch Set: Remove explicit HTTP/2 enum usage Created 4 years 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/tools/quic/quic_client_base.h ('k') | net/tools/quic/quic_client_bin.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/tools/quic/quic_client_base.cc
diff --git a/net/tools/quic/quic_client_base.cc b/net/tools/quic/quic_client_base.cc
index 2b2715bb38ef7e36df321f8752a2c3289f3d8790..1b7ed1ed4ab747cac2af21c96f3644645ab47257 100644
--- a/net/tools/quic/quic_client_base.cc
+++ b/net/tools/quic/quic_client_base.cc
@@ -307,12 +307,16 @@ void QuicClientBase::WaitForStreamToClose(QuicStreamId id) {
}
}
-void QuicClientBase::WaitForCryptoHandshakeConfirmed() {
+bool QuicClientBase::WaitForCryptoHandshakeConfirmed() {
DCHECK(connected());
while (connected() && !session_->IsCryptoHandshakeConfirmed()) {
WaitForEvents();
}
+
+ // If the handshake fails due to a timeout, the connection will be closed.
+ LOG_IF(ERROR, !connected()) << "Handshake with server failed.";
+ return connected();
}
bool QuicClientBase::connected() const {
« no previous file with comments | « net/tools/quic/quic_client_base.h ('k') | net/tools/quic/quic_client_bin.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698