diff options
author | Igor Sysoev <igor@sysoev.ru> | 2008-08-26 17:19:26 +0000 |
---|---|---|
committer | Jonathan Kolb <jon@b0g.us> | 2008-08-26 17:19:26 +0000 |
commit | 7f93e22cb91f9c361f01dabfbaff759ee1fd3a7a (patch) | |
tree | 8d301d73232966f70740c7c66efb2be890ab808f /src/os/unix/ngx_files.c | |
parent | fb724e08fc0e4617f44952f664e0020076075b50 (diff) | |
download | nginx-0.7.13.tar.gz |
Changes with nginx 0.7.13 26 Aug 2008v0.7.13
*) Bugfix: nginx could not be built on Linux and Solaris; the bug had
appeared in 0.7.12.
Diffstat (limited to 'src/os/unix/ngx_files.c')
-rw-r--r-- | src/os/unix/ngx_files.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/src/os/unix/ngx_files.c b/src/os/unix/ngx_files.c index d3abdd9e2..8d2733821 100644 --- a/src/os/unix/ngx_files.c +++ b/src/os/unix/ngx_files.c @@ -280,7 +280,15 @@ ngx_open_glob(ngx_glob_t *gl) ngx_int_t ngx_read_glob(ngx_glob_t *gl, ngx_str_t *name) { - if (gl->n < (size_t) gl->pglob.gl_matchc) { + size_t count; + +#ifdef GLOB_NOMATCH + count = (size_t) gl->pglob.gl_pathc; +#else + count = (size_t) gl->pglob.gl_matchc; +#endif + + if (gl->n < count) { name->len = (size_t) ngx_strlen(gl->pglob.gl_pathv[gl->n]); name->data = (u_char *) gl->pglob.gl_pathv[gl->n]; |