aboutsummaryrefslogtreecommitdiff
path: root/src/http/ngx_http_file_cache.c
diff options
context:
space:
mode:
authorIgor Sysoev <igor@sysoev.ru>2011-07-24 20:04:47 +0000
committerIgor Sysoev <igor@sysoev.ru>2011-07-24 20:04:47 +0000
commitd8ce166e2e51de1bc179420c7faae7176d64cc07 (patch)
tree6895aa13bc6f06bff4097336b0dbb0c5c4982f31 /src/http/ngx_http_file_cache.c
parentc2cafadfa5358918d55b0688df24ea7f620be847 (diff)
downloadnginx-d8ce166e2e51de1bc179420c7faae7176d64cc07.tar.gz
nginx-d8ce166e2e51de1bc179420c7faae7176d64cc07.zip
do not close connection if cache file is too small: replace it with valid one
Diffstat (limited to 'src/http/ngx_http_file_cache.c')
-rw-r--r--src/http/ngx_http_file_cache.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/http/ngx_http_file_cache.c b/src/http/ngx_http_file_cache.c
index 24bb5494a..0d5880642 100644
--- a/src/http/ngx_http_file_cache.c
+++ b/src/http/ngx_http_file_cache.c
@@ -376,7 +376,7 @@ ngx_http_file_cache_read(ngx_http_request_t *r, ngx_http_cache_t *c)
if ((size_t) n < c->header_start) {
ngx_log_error(NGX_LOG_CRIT, r->connection->log, 0,
"cache file \"%s\" is too small", c->file.name.data);
- return NGX_ERROR;
+ return NGX_DECLINED;
}
h = (ngx_http_file_cache_header_t *) c->buf->pos;