diff options
author | Igor Sysoev <igor@sysoev.ru> | 2004-04-25 20:13:21 +0000 |
---|---|---|
committer | Igor Sysoev <igor@sysoev.ru> | 2004-04-25 20:13:21 +0000 |
commit | 3f4685f3ded30199ec0c61f98b016f5880330422 (patch) | |
tree | 9b633e6681f3b02123700dea850ba0083eb4d6cb /src/http/ngx_http_request.c | |
parent | a040f00167fa64e0bd5ea85f3c0551358e0ee544 (diff) | |
download | nginx-3f4685f3ded30199ec0c61f98b016f5880330422.tar.gz nginx-3f4685f3ded30199ec0c61f98b016f5880330422.zip |
nginx-0.0.3-2004-04-26-00:13:21 import
Diffstat (limited to 'src/http/ngx_http_request.c')
-rw-r--r-- | src/http/ngx_http_request.c | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/src/http/ngx_http_request.c b/src/http/ngx_http_request.c index 1697eefae..1e0362107 100644 --- a/src/http/ngx_http_request.c +++ b/src/http/ngx_http_request.c @@ -991,7 +991,7 @@ void ngx_http_finalize_request(ngx_http_request_t *r, int rc) clcf = ngx_http_get_module_loc_conf(r, ngx_http_core_module); if (!ngx_terminate - && !ngx_quit + && !ngx_exiting && r->keepalive != 0 && clcf->keepalive_timeout > 0) { @@ -1582,6 +1582,19 @@ void ngx_http_close_request(ngx_http_request_t *r, int error) } } + if (r->request_body + && r->request_body->temp_file + && r->request_body->temp_file->file.fd != NGX_INVALID_FILE) + { + if (ngx_close_file(r->request_body->temp_file->file.fd) + == NGX_FILE_ERROR) + { + ngx_log_error(NGX_LOG_ALERT, log, ngx_errno, + ngx_close_file_n " deleted file \"%s\" failed", + r->request_body->temp_file->file.name.data); + } + } + /* ctx->url was allocated from r->pool */ ctx = log->data; ctx->url = NULL; |