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

Unified Diff: net/quic/quic_spdy_stream.cc

Issue 1433063002: Override ReliableQuicStream::StopReading() to send RST_STREAM+NO_ERROR if CloseWriteSide() is calle… (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@106978852
Patch Set: Created 5 years, 1 month 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/quic/quic_spdy_stream.h ('k') | net/tools/quic/quic_spdy_server_stream_test.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/quic/quic_spdy_stream.cc
diff --git a/net/quic/quic_spdy_stream.cc b/net/quic/quic_spdy_stream.cc
index 6a835f81379361073498f9f5c26d78184d223b20..775348fc860806bcff54bf915ea14d67bb68c1ac 100644
--- a/net/quic/quic_spdy_stream.cc
+++ b/net/quic/quic_spdy_stream.cc
@@ -54,6 +54,17 @@ void QuicSpdyStream::CloseWriteSide() {
ReliableQuicStream::CloseWriteSide();
}
+void QuicSpdyStream::StopReading() {
+ if (version() > QUIC_VERSION_28 && !fin_received() && !rst_received() &&
+ write_side_closed() && !rst_sent()) {
+ DCHECK(fin_sent());
+ // Tell the peer to stop sending further data.
+ DVLOG(1) << ENDPOINT << "Send QUIC_STREAM_NO_ERROR on stream " << id();
+ Reset(QUIC_STREAM_NO_ERROR);
+ }
+ ReliableQuicStream::StopReading();
+}
+
size_t QuicSpdyStream::WriteHeaders(
const SpdyHeaderBlock& header_block,
bool fin,
« no previous file with comments | « net/quic/quic_spdy_stream.h ('k') | net/tools/quic/quic_spdy_server_stream_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698