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

Unified Diff: net/spdy/spdy_stream.cc

Issue 10810069: SPDY: Add WriteHeaders interface to SpdySession and SpdyStream (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: support AddEvent Created 8 years, 5 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
« net/spdy/spdy_session.cc ('K') | « net/spdy/spdy_stream.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/spdy/spdy_stream.cc
diff --git a/net/spdy/spdy_stream.cc b/net/spdy/spdy_stream.cc
index 4fe34362cad5ffb2250a942f1aa219a002419aec..5ccc7727f726f567285c252bc68e55addaf8a9f8 100644
--- a/net/spdy/spdy_stream.cc
+++ b/net/spdy/spdy_stream.cc
@@ -479,6 +479,14 @@ int SpdyStream::SendRequest(bool has_upload_data) {
return DoLoop(OK);
}
+int SpdyStream::WriteHeaders(const SpdyHeaderBlock& headers,
+ SpdyControlFlags flags) {
+ // Until the first headers by SYN_STREAM have been completely sent, we can
+ // not be sure that our stream_id is correct.
+ DCHECK_GT(io_state_, STATE_SEND_HEADERS_COMPLETE);
+ return session_->WriteHeaders(stream_id_, headers, flags);
+}
+
int SpdyStream::WriteStreamData(IOBuffer* data, int length,
SpdyDataFlags flags) {
// Until the headers have been completely sent, we can not be sure
« net/spdy/spdy_session.cc ('K') | « net/spdy/spdy_stream.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698