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

Unified Diff: net/spdy/bidirectional_stream_spdy_impl.cc

Issue 2227083002: Remove net::BidirectionalStream::Cancel (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix typo Created 4 years, 4 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/spdy/bidirectional_stream_spdy_impl.h ('k') | net/spdy/bidirectional_stream_spdy_impl_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/spdy/bidirectional_stream_spdy_impl.cc
diff --git a/net/spdy/bidirectional_stream_spdy_impl.cc b/net/spdy/bidirectional_stream_spdy_impl.cc
index 4f11cdf3e840b27398b5342d034ba40798ff4dcc..66050fefb51b50e7ce174dcc354fd6997aea6de6 100644
--- a/net/spdy/bidirectional_stream_spdy_impl.cc
+++ b/net/spdy/bidirectional_stream_spdy_impl.cc
@@ -41,7 +41,8 @@ BidirectionalStreamSpdyImpl::BidirectionalStreamSpdyImpl(
weak_factory_(this) {}
BidirectionalStreamSpdyImpl::~BidirectionalStreamSpdyImpl() {
- Cancel();
+ // Sends a RST to the remote if the stream is destroyed before it completes.
+ ResetStream();
}
void BidirectionalStreamSpdyImpl::Start(
@@ -151,15 +152,6 @@ void BidirectionalStreamSpdyImpl::SendvData(
end_stream ? NO_MORE_DATA_TO_SEND : MORE_DATA_TO_SEND);
}
-void BidirectionalStreamSpdyImpl::Cancel() {
- if (delegate_) {
- delegate_ = nullptr;
- // Cancel any pending callback.
- weak_factory_.InvalidateWeakPtrs();
- }
- ResetStream();
-}
-
NextProto BidirectionalStreamSpdyImpl::GetProtocol() const {
return negotiated_protocol_;
}
« no previous file with comments | « net/spdy/bidirectional_stream_spdy_impl.h ('k') | net/spdy/bidirectional_stream_spdy_impl_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698