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

Unified Diff: net/http/http_stream_factory_impl_request.cc

Issue 344603004: Avoid setting a duplicate SpdySessionKey on a Request (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Windows compile fix. Created 6 years, 6 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
« no previous file with comments | « net/http/http_stream_factory_impl_request.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/http/http_stream_factory_impl_request.cc
diff --git a/net/http/http_stream_factory_impl_request.cc b/net/http/http_stream_factory_impl_request.cc
index c8924d25ad962f5ad064b57a1a6c4fb2e95d08e0..2cc497f2112371b1d80ed5d40f23cb9346076f49 100644
--- a/net/http/http_stream_factory_impl_request.cc
+++ b/net/http/http_stream_factory_impl_request.cc
@@ -54,7 +54,7 @@ HttpStreamFactoryImpl::Request::~Request() {
void HttpStreamFactoryImpl::Request::SetSpdySessionKey(
const SpdySessionKey& spdy_session_key) {
- DCHECK(!spdy_session_key_.get());
+ CHECK(!spdy_session_key_.get());
spdy_session_key_.reset(new SpdySessionKey(spdy_session_key));
RequestSet& request_set =
factory_->spdy_session_request_map_[spdy_session_key];
@@ -250,6 +250,10 @@ HttpStreamFactoryImpl::Request::RemoveRequestFromSpdySessionRequestMap() {
}
}
+bool HttpStreamFactoryImpl::Request::HasSpdySessionKey() const {
+ return spdy_session_key_.get() != NULL;
+}
+
// TODO(jgraettinger): Currently, HttpStreamFactoryImpl::Job notifies a
// Request that the session is ready, which in turn notifies it's delegate,
// and then it notifies HttpStreamFactoryImpl so that /other/ requests may
« no previous file with comments | « net/http/http_stream_factory_impl_request.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698