Fixed strict aliasing warnings with old GCC versions.

This commit is contained in:
Ruslan Ermilov 2015-07-16 14:20:48 +03:00
parent a2a8bd3bdb
commit 6dc03bf1a4
2 changed files with 2 additions and 2 deletions

View File

@ -159,7 +159,7 @@ ngx_http_upstream_init_zone(ngx_shm_zone_t *shm_zone, void *data)
/* copy peers to shared memory */ /* copy peers to shared memory */
peersp = (ngx_http_upstream_rr_peers_t **) &shpool->data; peersp = (ngx_http_upstream_rr_peers_t **) (void *) &shpool->data;
for (i = 0; i < umcf->upstreams.nelts; i++) { for (i = 0; i < umcf->upstreams.nelts; i++) {
uscf = uscfp[i]; uscf = uscfp[i];

View File

@ -155,7 +155,7 @@ ngx_stream_upstream_init_zone(ngx_shm_zone_t *shm_zone, void *data)
/* copy peers to shared memory */ /* copy peers to shared memory */
peersp = (ngx_stream_upstream_rr_peers_t **) &shpool->data; peersp = (ngx_stream_upstream_rr_peers_t **) (void *) &shpool->data;
for (i = 0; i < umcf->upstreams.nelts; i++) { for (i = 0; i < umcf->upstreams.nelts; i++) {
uscf = uscfp[i]; uscf = uscfp[i];