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

Unified Diff: net/quic/quic_stream_factory.cc

Issue 892203004: Make HttpServerProperties::GetSupportsQuic not host-specific. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 11 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
Index: net/quic/quic_stream_factory.cc
diff --git a/net/quic/quic_stream_factory.cc b/net/quic/quic_stream_factory.cc
index f957c18f6244c96ad192d3b4bcb154c6f7a837e8..0d707c2811625b3408e43915af172b2c3121128c 100644
--- a/net/quic/quic_stream_factory.cc
+++ b/net/quic/quic_stream_factory.cc
@@ -621,9 +621,8 @@ void QuicStreamFactory::set_require_confirmation(bool require_confirmation) {
if (http_server_properties_ && (!(local_address_ == IPEndPoint()))) {
// TODO(rtenneti): Delete host_port_pair and persist data in globals.
HostPortPair host_port_pair(kDummyHostname, kDummyPort);
ramant (doing other things) 2015/02/03 18:09:37 nit: line 623 could be deleted.
Ryan Hamilton 2015/02/03 22:50:45 *facepalm* Done.
- http_server_properties_->SetSupportsQuic(
- host_port_pair, !require_confirmation,
- local_address_.ToStringWithoutPort());
+ http_server_properties_->SetSupportsQuic(!require_confirmation,
+ local_address_.address());
}
}
@@ -1002,11 +1001,9 @@ int QuicStreamFactory::CreateSession(
socket->GetLocalAddress(&local_address_);
if (check_persisted_supports_quic_ && http_server_properties_) {
check_persisted_supports_quic_ = false;
- // TODO(rtenneti): Delete host_port_pair and persist data in globals.
- HostPortPair host_port_pair(kDummyHostname, kDummyPort);
- SupportsQuic supports_quic(true, local_address_.ToStringWithoutPort());
- if (http_server_properties_->GetSupportsQuic(
- host_port_pair).Equals(supports_quic)) {
+ IPAddressNumber last_address;
+ if (http_server_properties_->GetSupportsQuic(&last_address) &&
+ last_address == local_address_.address()) {
require_confirmation_ = false;
}
}

Powered by Google App Engine
This is Rietveld 408576698