]> granicus.if.org Git - curl/commit
http2: Ensure that http2_handle_stream_close is called
authorTatsuhiro Tsujikawa <tatsuhiro.t@gmail.com>
Thu, 7 Jan 2016 13:10:09 +0000 (22:10 +0900)
committerJay Satiro <raysatiro@yahoo.com>
Fri, 8 Jan 2016 22:16:47 +0000 (17:16 -0500)
commitb019af41e7d09cb75c461e33de5ce7a8c461dc43
treed54fa39aecabcc7385289af8e94c1535691c4f57
parent325686ef9eaf969830965ecaf044289cf8777f49
http2: Ensure that http2_handle_stream_close is called

Previously, when HTTP/2 is enabled and used, and stream has content
length known, Curl_read was not called when there was no bytes left to
read. Because of this, we could not make sure that
http2_handle_stream_close was called for every stream. Since we use
http2_handle_stream_close to emit trailer fields, they were
effectively ignored. This commit changes the code so that Curl_read is
called even if no bytes left to read, to ensure that
http2_handle_stream_close is called for every stream.

Discussed in https://github.com/bagder/curl/pull/564
lib/transfer.c