mirror of
https://github.com/nginx/nginx.git
synced 2024-12-01 03:17:17 +08:00
compare long file names in case-insensitive mode,
the bug had been introduced in r3418
This commit is contained in:
parent
416fc7aac7
commit
f953436886
@ -48,7 +48,7 @@ ngx_open_file(u_char *name, u_long mode, u_long create, u_long access)
|
|||||||
goto failed;
|
goto failed;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (n != len - 1 || ngx_memcmp(u, lu, n) != 0) {
|
if (n != len - 1 || _wcsicmp(u, lu) != 0) {
|
||||||
ngx_set_errno(NGX_ENOENT);
|
ngx_set_errno(NGX_ENOENT);
|
||||||
goto failed;
|
goto failed;
|
||||||
}
|
}
|
||||||
|
@ -36,6 +36,7 @@
|
|||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
|
#include <locale.h>
|
||||||
|
|
||||||
#ifdef __WATCOMC__
|
#ifdef __WATCOMC__
|
||||||
#define _TIME_T_DEFINED
|
#define _TIME_T_DEFINED
|
||||||
|
@ -114,6 +114,9 @@ ngx_os_init(ngx_log_t *log)
|
|||||||
|
|
||||||
for (n = ngx_pagesize; n >>= 1; ngx_pagesize_shift++) { /* void */ }
|
for (n = ngx_pagesize; n >>= 1; ngx_pagesize_shift++) { /* void */ }
|
||||||
|
|
||||||
|
/* delete default "C" locale for _wcsicmp() */
|
||||||
|
setlocale(LC_ALL, "");
|
||||||
|
|
||||||
|
|
||||||
/* init Winsock */
|
/* init Winsock */
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user