diff options
author | Igor Sysoev <igor@sysoev.ru> | 2009-04-01 16:28:06 +0000 |
---|---|---|
committer | Igor Sysoev <igor@sysoev.ru> | 2009-04-01 16:28:06 +0000 |
commit | e429f324e591c7dce1e23d308b981df5ea3156d4 (patch) | |
tree | 58faa8329fea0a93d8ba08fc443d8c7a77b62022 | |
parent | 27e2d99c32f070d085e5d926f42bce2e3945d2f6 (diff) | |
download | nginx-e429f324e591c7dce1e23d308b981df5ea3156d4.tar.gz |
r2490 merge:
avoid a double redirect response if
*) a request is going in a keep alive state,
*) the request body should be discarded,
*) epoll/rtsig reports about the response header has been sent,
*) and write event handler calls core phase handler
-rw-r--r-- | src/http/ngx_http_request.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/http/ngx_http_request.c b/src/http/ngx_http_request.c index deb283404..bcfe21bbc 100644 --- a/src/http/ngx_http_request.c +++ b/src/http/ngx_http_request.c @@ -2090,6 +2090,7 @@ ngx_http_set_keepalive(ngx_http_request_t *r) ngx_log_debug0(NGX_LOG_DEBUG_HTTP, c->log, 0, "set http keepalive handler"); if (r->discard_body) { + r->write_event_handler = ngx_http_request_empty_handler; r->lingering_time = ngx_time() + (time_t) (clcf->lingering_time / 1000); ngx_add_timer(rev, clcf->lingering_timeout); return; |