Mercurial > hg > nginx
comparison src/http/v2/ngx_http_v2.c @ 6956:9b5f31fdb850
HTTP/2: fixed stream finalization.
In order to finalize stream the error flag is set on fake connection and
either "write" or "read" event handler is called. The read events of fake
connections are always ready, but it's not the case with the write events.
When the ready flag isn't set, the error flag can be not checked in some
cases and as a result stream isn't finalized. Now the ready flag is
explicilty set on write events for proper finalization in all cases.
author | Valentin Bartenev <vbart@nginx.com> |
---|---|
date | Wed, 29 Mar 2017 20:16:23 +0300 |
parents | d38161da62cd |
children | 83bae3d354ab |
comparison
equal
deleted
inserted
replaced
6955:d38161da62cd | 6956:9b5f31fdb850 |
---|---|
4264 | 4264 |
4265 fc->error = 1; | 4265 fc->error = 1; |
4266 | 4266 |
4267 if (stream->queued) { | 4267 if (stream->queued) { |
4268 stream->queued = 0; | 4268 stream->queued = 0; |
4269 | |
4269 ev = fc->write; | 4270 ev = fc->write; |
4271 ev->active = 0; | |
4272 ev->ready = 1; | |
4270 | 4273 |
4271 } else { | 4274 } else { |
4272 ev = fc->read; | 4275 ev = fc->read; |
4273 } | 4276 } |
4274 | 4277 |