comparison 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
comparison
equal deleted inserted replaced
3199:b242aaf1dcfa 3200:26784c34e8be
173 continue; 173 continue;
174 } 174 }
175 175
176 len = ngx_de_namelen(&dir); 176 len = ngx_de_namelen(&dir);
177 177
178 if (!dir.valid_type) { 178 if (dir.type == 0) {
179 179
180 /* 1 byte for '/' and 1 byte for terminating '\0' */ 180 /* 1 byte for '/' and 1 byte for terminating '\0' */
181 181
182 if (path.len + 1 + len + 1 > allocated) { 182 if (path.len + 1 + len + 1 > allocated) {
183 allocated = path.len + 1 + len + 1 183 allocated = path.len + 1 + len + 1