]> git.kaiwu.me - nginx.git/commitdiff
Merge of r4944: removed GLOB_NOSORT glob option.
authorMaxim Dounin <mdounin@mdounin.ru>
Sat, 9 Feb 2013 21:27:37 +0000 (21:27 +0000)
committerMaxim Dounin <mdounin@mdounin.ru>
Sat, 9 Feb 2013 21:27:37 +0000 (21:27 +0000)
This will result in alphabetical sorting of included files if
the "include" directive with wildcards is used.

Note that the behaviour is now different from that on Windows, where
alphabetical sorting is not guaranteed for FindFirsFile()/FindNextFile()
(used to be alphabetical on NTFS, but not on FAT).

Approved by Igor Sysoev, prodded by many.

src/os/unix/ngx_files.c

index 4fdf884fc65c25572f4ddccd344e0399a4e819b9..c3ae47fdbf6873dfb7698a0b802d9039e8d738fa 100644 (file)
@@ -363,7 +363,7 @@ ngx_open_glob(ngx_glob_t *gl)
 {
     int  n;
 
-    n = glob((char *) gl->pattern, GLOB_NOSORT, NULL, &gl->pglob);
+    n = glob((char *) gl->pattern, 0, NULL, &gl->pglob);
 
     if (n == 0) {
         return NGX_OK;