# HG changeset patch # User Igor Sysoev # Date 1171180152 0 # Node ID 01884449985f3c88be3a044ca117a6c5d56272f6 # Parent 04a8b485447d7211f83970a64d155f930105072b fix building on platforms with non-supported atomic operations diff --git a/src/core/ngx_cycle.c b/src/core/ngx_cycle.c --- a/src/core/ngx_cycle.c +++ b/src/core/ngx_cycle.c @@ -901,7 +901,8 @@ ngx_test_lockfile(u_char *file, ngx_log_ #if !(NGX_HAVE_ATOMIC_OPS) ngx_fd_t fd; - fd = ngx_open_file(file, NGX_FILE_RDWR, NGX_FILE_CREATE_OR_OPEN); + fd = ngx_open_file(file, NGX_FILE_RDWR, NGX_FILE_CREATE_OR_OPEN, + NGX_FILE_DEFAULT_ACCESS); if (fd == NGX_INVALID_FILE) { ngx_log_error(NGX_LOG_EMERG, log, ngx_errno, diff --git a/src/core/ngx_shmtx.c b/src/core/ngx_shmtx.c --- a/src/core/ngx_shmtx.c +++ b/src/core/ngx_shmtx.c @@ -35,7 +35,8 @@ ngx_shmtx_create(ngx_shmtx_t *mtx, void ngx_shmtx_destory(mtx); } - mtx->fd = ngx_open_file(name, NGX_FILE_RDWR, NGX_FILE_CREATE_OR_OPEN); + mtx->fd = ngx_open_file(name, NGX_FILE_RDWR, NGX_FILE_CREATE_OR_OPEN, + NGX_FILE_DEFAULT_ACCESS); if (mtx->fd == NGX_INVALID_FILE) { ngx_log_error(NGX_LOG_EMERG, ngx_cycle->log, ngx_errno,