commit | 6b9c135cd9e20cabe3d2d4bc0bb7ee3fc33392a6 | [log] [tgz] |
---|---|---|
author | Bence Béky <bnc@chromium.org> | Thu May 10 11:51:25 2018 |
committer | Commit Bot <commit-bot@chromium.org> | Thu May 10 11:51:25 2018 |
tree | 8932f940e038717f36c9369342578fe4a647ccf1 | |
parent | 59f892fc9d3c442f4381ebd220658b19644812ba [diff] |
Close HTTP/2 stream with proper error code. Currently when SpdyStream::Delegate calls SpdyStream::Cancel(), that calls SpdySession::ResetStream(), which calls SpdySession::ResetStreamIterator(), which calls SpdySession::CloseActiveStreamIterator() with ERR_SPDY_PROTOCOL_ERROR, which calls SpdySession::DeleteStream() with ERR_SPDY_PROTOCOL_ERROR, which calls SpdyStream::OnClose() with ERR_SPDY_PROTOCOL_ERROR, which calls SpdyStream::Delegate::OnClose() with ERR_SPDY_PROTOCOL_ERROR. After this CL, SpdyStream::Cancel() takes an int error argument, which is passed to SpdySession::ResetStream() then to SpdySession::ResetStreamIterator() then to SpdySession::CloseActiveStreamIterator() then to SpdySession::DeleteStream() then to SpdyStream::OnClose() then to SpdyStream::Delegate::OnClose(). This way Delegate can directly control what error its own OnClose() method will be called with. This will be useful if I end up moving HTTP/2 pushed header validation to SpdyHttpStream, so that it can use a dedicated error code to signal to HttpNetworkTransaction if the pushed stream does not match. Bug: 554220 Change-Id: Id6395d834395d182b7af4a45e1bb1186c1b82feb Reviewed-on: https://chromium-review.googlesource.com/1051007 Reviewed-by: Ryan Hamilton <rch@chromium.org> Commit-Queue: Bence Béky <bnc@chromium.org> Cr-Commit-Position: refs/heads/master@{#557493}
Chromium is an open-source browser project that aims to build a safer, faster, and more stable way for all users to experience the web.
The project's web site is https://www.chromium.org.
Documentation in the source is rooted in docs/README.md.
Learn how to Get Around the Chromium Source Code Directory Structure .