diff options
author | Igor Sysoev <igor@sysoev.ru> | 2011-08-01 13:52:54 +0000 |
---|---|---|
committer | Igor Sysoev <igor@sysoev.ru> | 2011-08-01 13:52:54 +0000 |
commit | 21fd22d089d92f4f1db5ad776545c3c8d389ce1d (patch) | |
tree | b8fa512bb4652c368bf5fbc1cabeb29cde654c59 /src/http/ngx_http_request.c | |
parent | 2505587b4d87479bac239635cec2b893885795fd (diff) | |
download | nginx-21fd22d089d92f4f1db5ad776545c3c8d389ce1d.tar.gz nginx-21fd22d089d92f4f1db5ad776545c3c8d389ce1d.zip |
always set timer in discard body handler, this fixes the cases
when request for static file is redirected by error_page to an SSI page
patch by Maxim Dounin
Diffstat (limited to 'src/http/ngx_http_request.c')
-rw-r--r-- | src/http/ngx_http_request.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/http/ngx_http_request.c b/src/http/ngx_http_request.c index d11b13e4a..5e0b8e891 100644 --- a/src/http/ngx_http_request.c +++ b/src/http/ngx_http_request.c @@ -2123,11 +2123,11 @@ ngx_http_finalize_connection(ngx_http_request_t *r) if (r->discard_body) { r->read_event_handler = ngx_http_discarded_request_body_handler; + ngx_add_timer(r->connection->read, clcf->lingering_timeout); if (r->lingering_time == 0) { r->lingering_time = ngx_time() + (time_t) (clcf->lingering_time / 1000); - ngx_add_timer(r->connection->read, clcf->lingering_timeout); } } |