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

Unified Diff: net/http/http_stream_factory.cc

Issue 701163002: Introduce AlternateProtocolInfo.is_broken. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Nit. Created 6 years, 1 month 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/http/http_server_properties_manager.cc ('k') | net/http/http_stream_factory_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/http/http_stream_factory.cc
diff --git a/net/http/http_stream_factory.cc b/net/http/http_stream_factory.cc
index e86d8f89b071a9216854512694d174aaa85475a2..29d9b2642cfcd956b97c5eb3d78afdb784bc549d 100644
--- a/net/http/http_stream_factory.cc
+++ b/net/http/http_stream_factory.cc
@@ -67,14 +67,10 @@ void HttpStreamFactory::ProcessAlternateProtocol(
return;
}
- protocol =
- AlternateProtocolFromString(port_protocol_vector[1]);
+ protocol = AlternateProtocolFromString(port_protocol_vector[1]);
+
if (IsAlternateProtocolValid(protocol) &&
!session.IsProtocolEnabled(protocol)) {
- protocol = ALTERNATE_PROTOCOL_BROKEN;
- }
-
- if (protocol == ALTERNATE_PROTOCOL_BROKEN) {
DVLOG(1) << kAlternateProtocolHeader
<< " header has unrecognized protocol: "
<< port_protocol_vector[1];
@@ -94,7 +90,7 @@ void HttpStreamFactory::ProcessAlternateProtocol(
const AlternateProtocolInfo existing_alternate =
http_server_properties->GetAlternateProtocol(host_port);
// If we think the alternate protocol is broken, don't change it.
- if (existing_alternate.protocol == ALTERNATE_PROTOCOL_BROKEN)
+ if (existing_alternate.is_broken)
return;
}
« no previous file with comments | « net/http/http_server_properties_manager.cc ('k') | net/http/http_stream_factory_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698