upstream 0.7.33
[nginx.git] / nginx / src / http / ngx_http_request.c
index 1a774e4..3a1c5f7 100644 (file)
@@ -2185,6 +2185,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;