Mercurial > hg > nginx
diff src/http/ngx_http_request.c @ 3985:07d1aa82899b
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
author | Igor Sysoev <igor@sysoev.ru> |
---|---|
date | Mon, 01 Aug 2011 13:52:54 +0000 |
parents | 3e51832c8215 |
children | 4e1a489c26cd |
line wrap: on
line diff
--- a/src/http/ngx_http_request.c Mon Aug 01 13:26:55 2011 +0000 +++ b/src/http/ngx_http_request.c Mon Aug 01 13:52:54 2011 +0000 @@ -2123,11 +2123,11 @@ 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); } }