diff options
author | akalin@chromium.org <akalin@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-07-25 00:39:35 +0000 |
---|---|---|
committer | akalin@chromium.org <akalin@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-07-25 00:39:35 +0000 |
commit | d8cef8593844f828738cd6afc76ac04845966fa5 (patch) | |
tree | fe023c34005e2cc44a0846d981882adef0324c12 /net/spdy/spdy_session.h | |
parent | 675ee34e944a14898467ce712c4df595c826d732 (diff) | |
download | chromium_src-d8cef8593844f828738cd6afc76ac04845966fa5.zip chromium_src-d8cef8593844f828738cd6afc76ac04845966fa5.tar.gz chromium_src-d8cef8593844f828738cd6afc76ac04845966fa5.tar.bz2 |
[SPDY] Send a RST_STREAM frame before closing the associated stream
Closing the stream may close the corresponding session.
This is a speculative fix for the bug below.
BUG=263691
R=rch@chromium.org
Review URL: https://codereview.chromium.org/20163002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@213561 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net/spdy/spdy_session.h')
-rw-r--r-- | net/spdy/spdy_session.h | 18 |
1 files changed, 11 insertions, 7 deletions
diff --git a/net/spdy/spdy_session.h b/net/spdy/spdy_session.h index 4965255..fedd701 100644 --- a/net/spdy/spdy_session.h +++ b/net/spdy/spdy_session.h @@ -590,17 +590,21 @@ class NET_EXPORT SpdySession : public BufferedSpdyFramerVisitorInterface, // stream may hold the last reference to the session. void CloseCreatedStreamIterator(CreatedStreamSet::iterator it, int status); - // Calls CloseActiveStreamIterator() and then SendResetStreamFrame(). + // Calls EnqueueResetStreamFrame() and then + // CloseActiveStreamIterator(). void ResetStreamIterator(ActiveStreamMap::iterator it, SpdyRstStreamStatus status, const std::string& description); - // Send a RST_STREAM frame with the given parameters. There must be - // no active stream with the given ID. - void SendResetStreamFrame(SpdyStreamId stream_id, - RequestPriority priority, - SpdyRstStreamStatus status, - const std::string& description); + // Send a RST_STREAM frame with the given parameters. There should + // either be no active stream with the given ID, or that active + // stream should be closed shortly after this function is called. + // + // TODO(akalin): Rename this to EnqueueResetStreamFrame(). + void EnqueueResetStreamFrame(SpdyStreamId stream_id, + RequestPriority priority, + SpdyRstStreamStatus status, + const std::string& description); // Calls DoReadLoop and then if |availability_state_| is // STATE_CLOSED, calls RemoveFromPool(). |