comparison src/os/win32/ngx_files.h @ 1048:c4f666fc3a7e

ngx_open_file(name, access, create) > ngx_open_file(name, mode, create, access)
author Igor Sysoev <igor@sysoev.ru>
date Thu, 18 Jan 2007 20:15:09 +0000
parents ea6f43a88208
children 8865ca5ff560
comparison
equal deleted inserted replaced
1047:ea6f43a88208 1048:c4f666fc3a7e
26 #define NGX_INVALID_FILE INVALID_HANDLE_VALUE 26 #define NGX_INVALID_FILE INVALID_HANDLE_VALUE
27 #define NGX_FILE_ERROR 0 27 #define NGX_FILE_ERROR 0
28 28
29 29
30 30
31 #define ngx_open_file(name, access, create) \ 31 #define ngx_open_file(name, mode, create, access) \
32 CreateFile((const char *) name, access, \ 32 CreateFile((const char *) name, mode, \
33 FILE_SHARE_READ|FILE_SHARE_WRITE|FILE_SHARE_DELETE, \ 33 FILE_SHARE_READ|FILE_SHARE_WRITE|FILE_SHARE_DELETE, \
34 NULL, create, FILE_FLAG_BACKUP_SEMANTICS, NULL) 34 NULL, create, FILE_FLAG_BACKUP_SEMANTICS, NULL)
35 /* 35 /*
36 NULL, OPEN_EXISTING, 0, NULL) 36 NULL, OPEN_EXISTING, 0, NULL)
37 */ 37 */
40 #define NGX_FILE_RDONLY GENERIC_READ 40 #define NGX_FILE_RDONLY GENERIC_READ
41 #define NGX_FILE_RDWR GENERIC_READ|GENERIC_WRITE 41 #define NGX_FILE_RDWR GENERIC_READ|GENERIC_WRITE
42 #define NGX_FILE_CREATE_OR_OPEN OPEN_ALWAYS 42 #define NGX_FILE_CREATE_OR_OPEN OPEN_ALWAYS
43 #define NGX_FILE_OPEN OPEN_EXISTING 43 #define NGX_FILE_OPEN OPEN_EXISTING
44 #define NGX_FILE_APPEND 0 44 #define NGX_FILE_APPEND 0
45
46 #define NGX_FILE_DEFAULT_ACCESS 0
45 47
46 48
47 ngx_int_t ngx_file_append_mode(ngx_fd_t fd); 49 ngx_int_t ngx_file_append_mode(ngx_fd_t fd);
48 #define ngx_file_append_mode_n "SetFilePointer()" 50 #define ngx_file_append_mode_n "SetFilePointer()"
49 51