diff options
Diffstat (limited to 'src/os/unix')
-rw-r--r-- | src/os/unix/ngx_atomic.h | 8 | ||||
-rw-r--r-- | src/os/unix/ngx_solaris_sendfilev_chain.c | 3 |
2 files changed, 5 insertions, 6 deletions
diff --git a/src/os/unix/ngx_atomic.h b/src/os/unix/ngx_atomic.h index 41c670475..7f740381b 100644 --- a/src/os/unix/ngx_atomic.h +++ b/src/os/unix/ngx_atomic.h @@ -86,7 +86,7 @@ static ngx_inline uint32_t ngx_atomic_inc(ngx_atomic_t *value) __asm__ volatile ( - "casa [%1]ASI_P, %2, %0" + "casa [%1] 0x80, %2, %0" : "+r" (res) : "r" (value), "r" (old)); @@ -112,7 +112,7 @@ static ngx_inline uint32_t ngx_atomic_cmp_set(ngx_atomic_t *lock, __asm__ volatile ( - "casa [%1]ASI_P, %2, %0" + "casa [%1] 0x80, %2, %0" : "+r" (res) : "r" (lock), "r" (old)); @@ -124,8 +124,8 @@ static ngx_inline uint32_t ngx_atomic_cmp_set(ngx_atomic_t *lock, typedef volatile uint32_t ngx_atomic_t; /* STUB */ -#define ngx_atomic_inc(x) (*(x))++; -#define ngx_atomic_dec(x) (*(x))--; +#define ngx_atomic_inc(x) ++(*(x)); +#define ngx_atomic_dec(x) --(*(x)); #define ngx_atomic_cmp_set(lock, old, set) 1 /**/ diff --git a/src/os/unix/ngx_solaris_sendfilev_chain.c b/src/os/unix/ngx_solaris_sendfilev_chain.c index d249e8186..f6dca9c15 100644 --- a/src/os/unix/ngx_solaris_sendfilev_chain.c +++ b/src/os/unix/ngx_solaris_sendfilev_chain.c @@ -18,8 +18,7 @@ ngx_chain_t *ngx_solaris_sendfilev_chain(ngx_connection_t *c, ngx_chain_t *in, int fd; u_char *prev; off_t fprev, sprev, send, aligned; - size_t size, sent; - ssize_t n; + ssize_t size, sent, n; ngx_int_t eintr, complete; ngx_err_t err; sendfilevec_t *sfv, sfvs[NGX_SENDFILEVECS]; |