merge r2952:
ignore ngx_atomic_fetch_add() result
this fixes building at least by gcc 4.2.1 on Mac OS X 10.6
diff --git a/src/event/ngx_event_accept.c b/src/event/ngx_event_accept.c
index a17d630..05624ad 100644
--- a/src/event/ngx_event_accept.c
+++ b/src/event/ngx_event_accept.c
@@ -75,7 +75,7 @@
}
#if (NGX_STAT_STUB)
- ngx_atomic_fetch_add(ngx_stat_accepted, 1);
+ (void) ngx_atomic_fetch_add(ngx_stat_accepted, 1);
#endif
ngx_accept_disabled = ngx_cycle->connection_n / 8
@@ -93,7 +93,7 @@
}
#if (NGX_STAT_STUB)
- ngx_atomic_fetch_add(ngx_stat_active, 1);
+ (void) ngx_atomic_fetch_add(ngx_stat_active, 1);
#endif
c->pool = ngx_create_pool(ls->pool_size, ev->log);
@@ -188,7 +188,7 @@
c->number = ngx_atomic_fetch_add(ngx_connection_counter, 1);
#if (NGX_STAT_STUB)
- ngx_atomic_fetch_add(ngx_stat_handled, 1);
+ (void) ngx_atomic_fetch_add(ngx_stat_handled, 1);
#endif
#if (NGX_THREADS)
@@ -379,7 +379,7 @@
}
#if (NGX_STAT_STUB)
- ngx_atomic_fetch_add(ngx_stat_active, -1);
+ (void) ngx_atomic_fetch_add(ngx_stat_active, -1);
#endif
}
diff --git a/src/http/ngx_http_request.c b/src/http/ngx_http_request.c
index 4e799e9..b108394 100644
--- a/src/http/ngx_http_request.c
+++ b/src/http/ngx_http_request.c
@@ -198,7 +198,7 @@
c->write->handler = ngx_http_empty_handler;
#if (NGX_STAT_STUB)
- ngx_atomic_fetch_add(ngx_stat_reading, 1);
+ (void) ngx_atomic_fetch_add(ngx_stat_reading, 1);
#endif
if (rev->ready) {
@@ -217,7 +217,7 @@
if (ngx_handle_read_event(rev, 0) != NGX_OK) {
#if (NGX_STAT_STUB)
- ngx_atomic_fetch_add(ngx_stat_reading, -1);
+ (void) ngx_atomic_fetch_add(ngx_stat_reading, -1);
#endif
ngx_http_close_connection(c);
return;
@@ -247,7 +247,7 @@
#endif
#if (NGX_STAT_STUB)
- ngx_atomic_fetch_add(ngx_stat_reading, -1);
+ (void) ngx_atomic_fetch_add(ngx_stat_reading, -1);
#endif
c = rev->data;
@@ -497,9 +497,9 @@
r->log_handler = ngx_http_log_error_handler;
#if (NGX_STAT_STUB)
- ngx_atomic_fetch_add(ngx_stat_reading, 1);
+ (void) ngx_atomic_fetch_add(ngx_stat_reading, 1);
r->stat_reading = 1;
- ngx_atomic_fetch_add(ngx_stat_requests, 1);
+ (void) ngx_atomic_fetch_add(ngx_stat_requests, 1);
#endif
rev->handler(rev);
@@ -1544,9 +1544,9 @@
}
#if (NGX_STAT_STUB)
- ngx_atomic_fetch_add(ngx_stat_reading, -1);
+ (void) ngx_atomic_fetch_add(ngx_stat_reading, -1);
r->stat_reading = 0;
- ngx_atomic_fetch_add(ngx_stat_writing, 1);
+ (void) ngx_atomic_fetch_add(ngx_stat_writing, 1);
r->stat_writing = 1;
#endif
@@ -2316,7 +2316,7 @@
ngx_log_debug0(NGX_LOG_DEBUG_HTTP, c->log, 0, "pipelined request");
#if (NGX_STAT_STUB)
- ngx_atomic_fetch_add(ngx_stat_reading, 1);
+ (void) ngx_atomic_fetch_add(ngx_stat_reading, 1);
#endif
hc->pipeline = 1;
@@ -2546,7 +2546,7 @@
b->last += n;
#if (NGX_STAT_STUB)
- ngx_atomic_fetch_add(ngx_stat_reading, 1);
+ (void) ngx_atomic_fetch_add(ngx_stat_reading, 1);
#endif
c->log->handler = ngx_http_log_error;
@@ -2775,11 +2775,11 @@
#if (NGX_STAT_STUB)
if (r->stat_reading) {
- ngx_atomic_fetch_add(ngx_stat_reading, -1);
+ (void) ngx_atomic_fetch_add(ngx_stat_reading, -1);
}
if (r->stat_writing) {
- ngx_atomic_fetch_add(ngx_stat_writing, -1);
+ (void) ngx_atomic_fetch_add(ngx_stat_writing, -1);
}
#endif
@@ -2860,7 +2860,7 @@
#endif
#if (NGX_STAT_STUB)
- ngx_atomic_fetch_add(ngx_stat_active, -1);
+ (void) ngx_atomic_fetch_add(ngx_stat_active, -1);
#endif
c->destroyed = 1;
diff --git a/src/mail/ngx_mail_handler.c b/src/mail/ngx_mail_handler.c
index 44f202e..9cc6a07 100644
--- a/src/mail/ngx_mail_handler.c
+++ b/src/mail/ngx_mail_handler.c
@@ -710,7 +710,7 @@
#endif
#if (NGX_STAT_STUB)
- ngx_atomic_fetch_add(ngx_stat_active, -1);
+ (void) ngx_atomic_fetch_add(ngx_stat_active, -1);
#endif
c->destroyed = 1;