Index: net/http/http_network_layer.cc |
=================================================================== |
--- net/http/http_network_layer.cc (revision 57015) |
+++ net/http/http_network_layer.cc (working copy) |
@@ -148,7 +148,9 @@ |
static const char kDisableCompression[] = "no-compress"; |
static const char kDisableAltProtocols[] = "no-alt-protocols"; |
static const char kEnableVersionOne[] = "v1"; |
+ static const char kForceAltProtocols[] = "force-alt-protocols"; |
+ |
// If flow-control is enabled, received WINDOW_UPDATE and SETTINGS |
// messages are processed and outstanding window size is actually obeyed |
// when sending data frames, and WINDOW_UPDATE messages are generated |
@@ -210,6 +212,11 @@ |
HttpStreamFactory::set_use_alternate_protocols(false); |
} else if (option == kEnableFlowControl) { |
SpdySession::SetFlowControl(true); |
+ } else if (option == kForceAltProtocols) { |
+ HttpAlternateProtocols::PortProtocolPair pair; |
+ pair.port = 443; |
+ pair.protocol = HttpAlternateProtocols::NPN_SPDY_2; |
+ HttpAlternateProtocols::ForceAlternateProtocol(pair); |
} else if (option.empty() && it == spdy_options.begin()) { |
continue; |
} else { |