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

Unified Diff: mojo/services/network/http_connection_impl.cc

Issue 1138443004: Fix crash in network_service. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 7 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/services/network/http_connection_impl.cc
diff --git a/mojo/services/network/http_connection_impl.cc b/mojo/services/network/http_connection_impl.cc
index be306cd0c2e7a1c69d38c8f1ca8f7bdc5f88b0de..0831d1d7a888bad97dcfad5faaaa7553acb0cfd9 100644
--- a/mojo/services/network/http_connection_impl.cc
+++ b/mojo/services/network/http_connection_impl.cc
@@ -141,8 +141,9 @@ void HttpConnectionImpl::OnReceivedHttpRequest(
if (response->body.is_valid()) {
SimpleDataPipeReader* reader = new SimpleDataPipeReader;
response_body_readers_.insert(reader);
+ ScopedDataPipeConsumerHandle body = response->body.Pass();
reader->Start(
- response->body.Pass(),
+ body.Pass(),
base::Bind(&HttpConnectionImpl::OnFinishedReadingResponseBody,
base::Unretained(this), base::Passed(&response)));
} else {
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698