]> git.kaiwu.me - nginx.git/commit
Moved handling of wev->delayed to the connection event handler.
authorMaxim Dounin <mdounin@mdounin.ru>
Sun, 2 Apr 2017 11:32:29 +0000 (14:32 +0300)
committerMaxim Dounin <mdounin@mdounin.ru>
Sun, 2 Apr 2017 11:32:29 +0000 (14:32 +0300)
commit5d5f0dcac4e3bbd4464aa1185d7fd51587a3119e
treea5416b5d2589f61f3caa0ec749a1763dc7f19c53
parent96e4e84ce273664d0ee43c5c5b7d14efa6f86d39
Moved handling of wev->delayed to the connection event handler.

With post_action or subrequests, it is possible that the timer set for
wev->delayed will expire while the active subrequest write event handler
is not ready to handle this.  This results in request hangs as observed
with limit_rate / sendfile_max_chunk and post_action (ticket #776) or
subrequests (ticket #1228).

Moving the handling to the connection event handler fixes the hangs observed,
and also slightly simplifies the code.
src/http/modules/ngx_http_limit_req_module.c
src/http/modules/perl/ngx_http_perl_module.c
src/http/ngx_http_request.c
src/http/ngx_http_upstream.c