diff src/http/modules/ngx_http_random_index_module.c @ 3200:26784c34e8be

*) 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
author Igor Sysoev <igor@sysoev.ru>
date Wed, 14 Oct 2009 11:33:35 +0000
parents c7d57b539248
children a56cccd588e6
line wrap: on
line diff
--- 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_r
 
         len = ngx_de_namelen(&dir);
 
-        if (!dir.valid_type) {
+        if (dir.type == 0) {
 
             /* 1 byte for '/' and 1 byte for terminating '\0' */