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

Unified Diff: net/spdy/spdy_session.cc

Issue 169643006: Use sockets with unread data if they've never been used before. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Tweak SpdySession::IsReused (erf, got mixed in with a rebase) Created 6 years, 9 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
« net/socket/ssl_client_socket_unittest.cc ('K') | « net/spdy/spdy_session.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/spdy/spdy_session.cc
diff --git a/net/spdy/spdy_session.cc b/net/spdy/spdy_session.cc
index 093604b2d7802c20cfd5970dd609a309743e620a..d23ca1d88b8a57ff0d1b2a427605b27a615ca957 100644
--- a/net/spdy/spdy_session.cc
+++ b/net/spdy/spdy_session.cc
@@ -1680,7 +1680,8 @@ base::Value* SpdySession::GetInfoAsValue() const {
}
bool SpdySession::IsReused() const {
- return buffered_spdy_framer_->frames_received() > 0;
+ return buffered_spdy_framer_->frames_received() > 0 ||
mmenke 2014/03/18 15:16:55 Hrm... If we always received a settings frame fir
davidben 2014/03/18 22:53:55 SETTINGS frames aren't counted in this. It's oddly
+ connection_->reuse_type() == ClientSocketHandle::UNUSED_IDLE;
mmenke 2014/03/18 15:16:55 can we just use connection->is_reused()? Yes, it
davidben 2014/03/18 22:53:55 is_reused() is actually only REUSED_IDLE, not UNUS
}
bool SpdySession::GetLoadTimingInfo(SpdyStreamId stream_id,
« net/socket/ssl_client_socket_unittest.cc ('K') | « net/spdy/spdy_session.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698