Chromium Code Reviews| Index: net/http/http_stream_factory.cc |
| =================================================================== |
| --- net/http/http_stream_factory.cc (revision 124201) |
| +++ net/http/http_stream_factory.cc (working copy) |
| @@ -10,7 +10,6 @@ |
| #include "googleurl/src/gurl.h" |
| #include "net/base/host_mapping_rules.h" |
| #include "net/base/host_port_pair.h" |
| -#include "net/http/http_server_properties.h" |
| namespace net { |
| @@ -39,6 +38,8 @@ |
| uint16 HttpStreamFactory::testing_fixed_http_port_ = 0; |
| // static |
| uint16 HttpStreamFactory::testing_fixed_https_port_ = 0; |
| +// static |
| +AlternateProtocol HttpStreamFactory::supported_spdy_version_ = NPN_SPDY_2; |
| HttpStreamFactory::~HttpStreamFactory() {} |
| @@ -56,6 +57,7 @@ |
| force_spdy_always_ = false; |
| forced_spdy_exclusions_ = NULL; |
| ignore_certificate_errors_ = false; |
| + supported_spdy_version_ = NPN_SPDY_2; |
| } |
| void HttpStreamFactory::ProcessAlternateProtocol( |
| @@ -87,7 +89,8 @@ |
| protocol = static_cast<AlternateProtocol>(i); |
| } |
| - if (protocol == ALTERNATE_PROTOCOL_BROKEN) { |
| + if (protocol != supported_spdy_version_ || |
|
Ryan Hamilton
2012/03/01 18:56:20
As we discussed offline, this approach only allows
willchan no longer on Chromium
2012/03/01 18:57:54
Whew, good catch! I didn't notice this. This is im
|
| + protocol == ALTERNATE_PROTOCOL_BROKEN) { |
| // Currently, we only recognize the npn-spdy protocol. |
| DLOG(WARNING) << kAlternateProtocolHeader |
| << " header has unrecognized protocol: " |