mirror of
https://github.com/nginx/nginx.git
synced 2025-01-08 07:03:01 -06:00
fix building on platforms with non-supported atomic operations
This commit is contained in:
parent
915ef4f7c8
commit
8e750112f6
@ -901,7 +901,8 @@ ngx_test_lockfile(u_char *file, ngx_log_t *log)
|
|||||||
#if !(NGX_HAVE_ATOMIC_OPS)
|
#if !(NGX_HAVE_ATOMIC_OPS)
|
||||||
ngx_fd_t fd;
|
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) {
|
if (fd == NGX_INVALID_FILE) {
|
||||||
ngx_log_error(NGX_LOG_EMERG, log, ngx_errno,
|
ngx_log_error(NGX_LOG_EMERG, log, ngx_errno,
|
||||||
|
@ -35,7 +35,8 @@ ngx_shmtx_create(ngx_shmtx_t *mtx, void *addr, u_char *name)
|
|||||||
ngx_shmtx_destory(mtx);
|
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) {
|
if (mtx->fd == NGX_INVALID_FILE) {
|
||||||
ngx_log_error(NGX_LOG_EMERG, ngx_cycle->log, ngx_errno,
|
ngx_log_error(NGX_LOG_EMERG, ngx_cycle->log, ngx_errno,
|
||||||
|
Loading…
Reference in New Issue
Block a user