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

Unified Diff: net/socket/ssl_client_socket_pool.cc

Issue 12388099: [SPDY] Add flag to turn on SPDY/3.1 (with per-session flow control) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 10 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
« no previous file with comments | « net/socket/ssl_client_socket.cc ('k') | net/spdy/spdy_network_transaction_spdy3_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/socket/ssl_client_socket_pool.cc
diff --git a/net/socket/ssl_client_socket_pool.cc b/net/socket/ssl_client_socket_pool.cc
index 826ccc8a2ff6ef9f27e7226c30091e58b957fef1..64ebf28ce06432dd30d6a8243355f70bd3a4970d 100644
--- a/net/socket/ssl_client_socket_pool.cc
+++ b/net/socket/ssl_client_socket_pool.cc
@@ -301,12 +301,11 @@ int SSLConnectJob::DoSSLConnectComplete(int result) {
NextProto protocol_negotiated =
SSLClientSocket::NextProtoFromString(proto);
ssl_socket_->set_protocol_negotiated(protocol_negotiated);
- // If we negotiated either version of SPDY, we must have
- // advertised it, so allow it.
- // TODO(mbelshe): verify it was a protocol we advertised?
- if (protocol_negotiated == kProtoSPDY1 ||
- protocol_negotiated == kProtoSPDY2 ||
- protocol_negotiated == kProtoSPDY3) {
+ // If we negotiated a SPDY version, it must have been present in
+ // SSLConfig::next_protos.
+ // TODO(mbelshe): Verify this.
+ if (protocol_negotiated >= kProtoSPDYMinimumVersion &&
+ protocol_negotiated <= kProtoSPDYMaximumVersion) {
ssl_socket_->set_was_spdy_negotiated(true);
}
}
« no previous file with comments | « net/socket/ssl_client_socket.cc ('k') | net/spdy/spdy_network_transaction_spdy3_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698