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

Unified Diff: net/http/http_stream_factory_impl_request.cc

Issue 208663003: Revert of Fix SPDY error-handling if the connection gets closed just after use. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: 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
« no previous file with comments | « net/http/http_stream_factory_impl_request.h ('k') | net/spdy/spdy_session.h » ('j') | 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 5f129ac2673e6baca20a51c290129db841e7ddb1..ff66f1475ce4cdfb49f8665af92d1fcb5cac589f 100644
--- a/net/http/http_stream_factory_impl_request.cc
+++ b/net/http/http_stream_factory_impl_request.cc
@@ -291,15 +291,10 @@
void HttpStreamFactoryImpl::Request::OnNewSpdySessionReady(
Job* job,
- scoped_ptr<HttpStream> stream,
const base::WeakPtr<SpdySession>& spdy_session,
bool direct) {
DCHECK(job);
DCHECK(job->using_spdy());
-
- // Note: |spdy_session| may be NULL. In that case, |delegate_| should still
- // receive |stream| so the error propogates up correctly, however there is no
- // point in broadcasting |spdy_session| to other requests.
// The first case is the usual case.
if (!bound_job_.get()) {
@@ -327,20 +322,21 @@
// implemented.
NOTREACHED();
} else {
- delegate_->OnStreamReady(job->server_ssl_config(), job->proxy_info(),
- stream.release());
+ bool use_relative_url = direct || url().SchemeIs("https");
+ delegate_->OnStreamReady(
+ job->server_ssl_config(),
+ job->proxy_info(),
+ new SpdyHttpStream(spdy_session, use_relative_url));
}
// |this| may be deleted after this point.
- if (spdy_session) {
- factory->OnNewSpdySessionReady(spdy_session,
- direct,
- used_ssl_config,
- used_proxy_info,
- was_npn_negotiated,
- protocol_negotiated,
- using_spdy,
- net_log);
- }
+ factory->OnNewSpdySessionReady(spdy_session,
+ direct,
+ used_ssl_config,
+ used_proxy_info,
+ was_npn_negotiated,
+ protocol_negotiated,
+ using_spdy,
+ net_log);
}
void HttpStreamFactoryImpl::Request::OrphanJobsExcept(Job* job) {
« no previous file with comments | « net/http/http_stream_factory_impl_request.h ('k') | net/spdy/spdy_session.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698