Whenever a directory contained a file that couldn't be stat()ed by nginx

(e.g. due to EACCESS), the fancyindex module would produce an error and
wouldn't generate any response to the user.

The new behavior is to log a non-critical error and keep serving the page
anyway.

Signed-off-by: Benoit Sigoure <tsunanet@gmail.com>
Signed-off-by: Adrian Perez <aperez@igalia.com>
pull/4/head v0.2.2
Benoit Sigoure 2010-03-07 21:06:35 -08:00 committed by Adrian Perez
parent 3d18805d3a
commit bcbf8144c6
1 changed files with 2 additions and 2 deletions

View File

@ -354,9 +354,9 @@ make_content_buf(
ngx_int_t err = ngx_errno; ngx_int_t err = ngx_errno;
if (err != NGX_ENOENT) { if (err != NGX_ENOENT) {
ngx_log_error(NGX_LOG_CRIT, r->connection->log, err, ngx_log_error(NGX_LOG_ERR, r->connection->log, err,
ngx_de_info_n " \"%s\" failed", filename); ngx_de_info_n " \"%s\" failed", filename);
return ngx_http_fancyindex_error(r, &dir, &path); continue;
} }
if (ngx_de_link_info(filename, &dir) == NGX_FILE_ERROR) { if (ngx_de_link_info(filename, &dir) == NGX_FILE_ERROR) {