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

Unified Diff: net/quic/chromium/quic_chromium_client_stream.cc

Issue 2861583004: Remove the QuicChromiumClientStream::Delegate::HasSendHeadersComplete() (Closed)
Patch Set: Rebase Created 3 years, 8 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/quic/chromium/quic_chromium_client_stream.h ('k') | net/quic/chromium/quic_http_stream.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/quic/chromium/quic_chromium_client_stream.cc
diff --git a/net/quic/chromium/quic_chromium_client_stream.cc b/net/quic/chromium/quic_chromium_client_stream.cc
index c150f5cd65797aef28d4a9d57e725f2223e6db39..08cd6d8eb5342ebc0532d4f1fb7745691be5da7e 100644
--- a/net/quic/chromium/quic_chromium_client_stream.cc
+++ b/net/quic/chromium/quic_chromium_client_stream.cc
@@ -29,6 +29,7 @@ QuicChromiumClientStream::QuicChromiumClientStream(
net_log_(net_log),
delegate_(nullptr),
headers_delivered_(false),
+ initial_headers_sent_(false),
session_(session),
can_migrate_(true),
weak_factory_(this) {}
@@ -133,15 +134,15 @@ size_t QuicChromiumClientStream::WriteHeaders(
NetLogEventType::QUIC_CHROMIUM_CLIENT_STREAM_SEND_REQUEST_HEADERS,
base::Bind(&QuicRequestNetLogCallback, id(), &header_block,
QuicSpdyStream::priority()));
- return QuicSpdyStream::WriteHeaders(std::move(header_block), fin,
- std::move(ack_listener));
+ size_t len = QuicSpdyStream::WriteHeaders(std::move(header_block), fin,
+ std::move(ack_listener));
+ initial_headers_sent_ = true;
+ return len;
}
SpdyPriority QuicChromiumClientStream::priority() const {
- if (delegate_ && delegate_->HasSendHeadersComplete()) {
- return QuicSpdyStream::priority();
- }
- return net::kV3HighestPriority;
+ return initial_headers_sent_ ? QuicSpdyStream::priority()
+ : kV3HighestPriority;
}
int QuicChromiumClientStream::WriteStreamData(
« no previous file with comments | « net/quic/chromium/quic_chromium_client_stream.h ('k') | net/quic/chromium/quic_http_stream.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698