aboutsummaryrefslogtreecommitdiff
path: root/src/http/modules/ngx_http_index_handler.c
diff options
context:
space:
mode:
authorIgor Sysoev <igor@sysoev.ru>2003-07-18 14:44:05 +0000
committerIgor Sysoev <igor@sysoev.ru>2003-07-18 14:44:05 +0000
commit8e1fbe61b69562d838aafda8d75798993f022d4a (patch)
tree62231a7769d67b79f11de63c079e05d93ee274ea /src/http/modules/ngx_http_index_handler.c
parent7f125081f4347118ba50066e6341e429b3a85c3c (diff)
downloadnginx-8e1fbe61b69562d838aafda8d75798993f022d4a.tar.gz
nginx-8e1fbe61b69562d838aafda8d75798993f022d4a.zip
nginx-0.0.1-2003-07-18-18:44:05 import
Diffstat (limited to 'src/http/modules/ngx_http_index_handler.c')
-rw-r--r--src/http/modules/ngx_http_index_handler.c15
1 files changed, 9 insertions, 6 deletions
diff --git a/src/http/modules/ngx_http_index_handler.c b/src/http/modules/ngx_http_index_handler.c
index 7051480fc..c6c111716 100644
--- a/src/http/modules/ngx_http_index_handler.c
+++ b/src/http/modules/ngx_http_index_handler.c
@@ -290,16 +290,19 @@ static char *ngx_http_index_set_index(ngx_conf_t *cf, ngx_command_t *cmd,
value = cf->args->elts;
if (value[1].data[0] == '/' && icf->indices.nelts == 0) {
- ngx_snprintf(ngx_conf_errstr, sizeof(ngx_conf_errstr) - 1,
- "first index \"%s\" must not be absolute", value[1].data);
- return ngx_conf_errstr;
+ ngx_conf_log_error(NGX_LOG_EMERG, cf, 0,
+ "first index \"%s\" in \"%s\" directive "
+ "must not be absolute",
+ value[1].data, cmd->name.data);
+ return NGX_CONF_ERROR;
}
for (i = 1; i < cf->args->nelts; i++) {
if (value[i].len == 0) {
- ngx_snprintf(ngx_conf_errstr, sizeof(ngx_conf_errstr) - 1,
- "index \"%s\" is invalid", value[i].data);
- return ngx_conf_errstr;
+ ngx_conf_log_error(NGX_LOG_EMERG, cf, 0,
+ "index \"%s\" in \"%s\" directive is invalid",
+ value[1].data, cmd->name.data);
+ return NGX_CONF_ERROR;
}
ngx_test_null(index, ngx_push_array(&icf->indices), NGX_CONF_ERROR);