Chromium Code Reviews| Index: net/http/disk_cache_based_quic_server_info.cc |
| diff --git a/net/http/disk_cache_based_quic_server_info.cc b/net/http/disk_cache_based_quic_server_info.cc |
| index 91625bc973cec0eee0174c9348fd858d127212f2..a7f2563e9bb6ab6dbc28844804bc3b132a9db43a 100644 |
| --- a/net/http/disk_cache_based_quic_server_info.cc |
| +++ b/net/http/disk_cache_based_quic_server_info.cc |
| @@ -7,6 +7,7 @@ |
| #include "base/bind.h" |
| #include "base/callback.h" |
| #include "base/logging.h" |
| +#include "base/strings/string_number_conversions.h" |
| #include "net/base/completion_callback.h" |
| #include "net/base/io_buffer.h" |
| #include "net/base/net_errors.h" |
| @@ -43,9 +44,9 @@ struct DiskCacheBasedQuicServerInfo::CacheOperationDataShim { |
| }; |
| DiskCacheBasedQuicServerInfo::DiskCacheBasedQuicServerInfo( |
| - const std::string& hostname, |
| + const HostPortPair& host_port_pair, |
| HttpCache* http_cache) |
| - : QuicServerInfo(hostname), |
| + : QuicServerInfo(host_port_pair), |
| weak_factory_(this), |
| data_shim_(new CacheOperationDataShim()), |
| io_callback_( |
| @@ -55,7 +56,7 @@ DiskCacheBasedQuicServerInfo::DiskCacheBasedQuicServerInfo( |
| state_(GET_BACKEND), |
| ready_(false), |
| found_entry_(false), |
| - hostname_(hostname), |
| + host_port_pair_(host_port_pair), |
| http_cache_(http_cache), |
| backend_(NULL), |
| entry_(NULL) { |
| @@ -113,7 +114,8 @@ DiskCacheBasedQuicServerInfo::~DiskCacheBasedQuicServerInfo() { |
| } |
| std::string DiskCacheBasedQuicServerInfo::key() const { |
| - return "quicserverinfo:" + hostname_; |
| + return "quicserverinfo:" + host_port_pair_.host() + ":" + |
| + base::UintToString(host_port_pair_.port()); |
|
wtc
2014/03/11 01:41:39
1. IMPORTANT: should the key include the scheme (h
wtc
2014/03/11 15:37:52
Raman, Ryan: I think the key should include the sc
wtc
2014/03/11 15:50:19
Ryan, thanks for the comment.
If we can get the s
ramant (doing other things)
2014/03/13 01:50:12
Called ToString method on quic_session_key. Curren
ramant (doing other things)
2014/03/13 01:50:12
Using <scheme>://<host>:port as the key. scheme f
ramant (doing other things)
2014/03/13 01:50:12
Done.
|
| } |
| void DiskCacheBasedQuicServerInfo::OnIOComplete(CacheOperationDataShim* unused, |