aboutsummaryrefslogtreecommitdiff
path: root/src/http/ngx_http_core_module.c
diff options
context:
space:
mode:
authorRuslan Ermilov <ru@nginx.com>2012-05-15 08:10:59 +0000
committerRuslan Ermilov <ru@nginx.com>2012-05-15 08:10:59 +0000
commite3bb319e34785fb5b9287888988166b6199f0746 (patch)
tree5202ecf2344e5233745d82a39f7e7352c8776cff /src/http/ngx_http_core_module.c
parent0215fcc9b8c6fa288ec2e445121cb0e092d79428 (diff)
downloadnginx-e3bb319e34785fb5b9287888988166b6199f0746.tar.gz
nginx-e3bb319e34785fb5b9287888988166b6199f0746.zip
Fixed win32 build after changes in r4624.
Diffstat (limited to 'src/http/ngx_http_core_module.c')
-rw-r--r--src/http/ngx_http_core_module.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/http/ngx_http_core_module.c b/src/http/ngx_http_core_module.c
index 471a53cf8..31832ceb8 100644
--- a/src/http/ngx_http_core_module.c
+++ b/src/http/ngx_http_core_module.c
@@ -2704,7 +2704,7 @@ ngx_http_get_forwarded_addr(ngx_http_request_t *r, ngx_addr_t *addr,
u_char *xff, size_t xfflen, ngx_array_t *proxies, int recursive)
{
u_char *p;
- in_addr_t *inaddr;
+ in_addr_t inaddr;
ngx_addr_t paddr;
ngx_cidr_t *cidr;
ngx_uint_t family, i;
@@ -2714,7 +2714,7 @@ ngx_http_get_forwarded_addr(ngx_http_request_t *r, ngx_addr_t *addr,
#endif
#if (NGX_SUPPRESS_WARN)
- inaddr = NULL;
+ inaddr = 0;
#if (NGX_HAVE_INET6)
inaddr6 = NULL;
#endif
@@ -2723,7 +2723,7 @@ ngx_http_get_forwarded_addr(ngx_http_request_t *r, ngx_addr_t *addr,
family = addr->sockaddr->sa_family;
if (family == AF_INET) {
- inaddr = &((struct sockaddr_in *) addr->sockaddr)->sin_addr.s_addr;
+ inaddr = ((struct sockaddr_in *) addr->sockaddr)->sin_addr.s_addr;
}
#if (NGX_HAVE_INET6)
@@ -2732,7 +2732,7 @@ ngx_http_get_forwarded_addr(ngx_http_request_t *r, ngx_addr_t *addr,
if (IN6_IS_ADDR_V4MAPPED(inaddr6)) {
family = AF_INET;
- inaddr = (in_addr_t *) &inaddr6->s6_addr[12];
+ inaddr = *(in_addr_t *) &inaddr6->s6_addr[12];
}
}
#endif
@@ -2762,7 +2762,7 @@ ngx_http_get_forwarded_addr(ngx_http_request_t *r, ngx_addr_t *addr,
#endif
default: /* AF_INET */
- if ((*inaddr & cidr[i].u.in.mask) != cidr[i].u.in.addr) {
+ if ((inaddr & cidr[i].u.in.mask) != cidr[i].u.in.addr) {
goto next;
}
break;