From e58700d3b08bee27db7206c2eefe858ad0488b4a Mon Sep 17 00:00:00 2001 From: Igor Sysoev Date: Wed, 14 Oct 2009 11:33:35 +0000 Subject: *) reset cached dirent.d_type after stat() this fixes slash after link to a directory in ngx_http_autoindex_module; *) use cached dirent.d_type as hint on all systems the issues has been introduced in r2235 --- src/http/modules/ngx_http_random_index_module.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/http') diff --git a/src/http/modules/ngx_http_random_index_module.c b/src/http/modules/ngx_http_random_index_module.c index bb5544ae6..29491f519 100644 --- a/src/http/modules/ngx_http_random_index_module.c +++ b/src/http/modules/ngx_http_random_index_module.c @@ -175,7 +175,7 @@ ngx_http_random_index_handler(ngx_http_request_t *r) len = ngx_de_namelen(&dir); - if (!dir.valid_type) { + if (dir.type == 0) { /* 1 byte for '/' and 1 byte for terminating '\0' */ -- cgit