summaryrefslogtreecommitdiffhomepage
path: root/src/http/modules
diff options
context:
space:
mode:
authorIgor Sysoev <igor@sysoev.ru>2009-05-18 12:58:19 +0000
committerIgor Sysoev <igor@sysoev.ru>2009-05-18 12:58:19 +0000
commit2a9ce6263164bedc4db70e0ad9fc6591605e38b0 (patch)
treeeee93b330dc9ac4ab4db3d14618bc3455be4b619 /src/http/modules
parent739e29b651dc0f6f176884cce697018b4b522a67 (diff)
downloadnginx-2a9ce6263164bedc4db70e0ad9fc6591605e38b0.tar.gz
nginx-2a9ce6263164bedc4db70e0ad9fc6591605e38b0.tar.bz2
use ngx_connection_local_sockaddr() instead of ngx_http_server_addr()
Diffstat (limited to 'src/http/modules')
-rw-r--r--src/http/modules/ngx_http_userid_filter_module.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/http/modules/ngx_http_userid_filter_module.c b/src/http/modules/ngx_http_userid_filter_module.c
index 5ffb1d02b..3462f649c 100644
--- a/src/http/modules/ngx_http_userid_filter_module.c
+++ b/src/http/modules/ngx_http_userid_filter_module.c
@@ -390,12 +390,13 @@ ngx_http_userid_set_uid(ngx_http_request_t *r, ngx_http_userid_ctx_t *ctx,
} else {
if (conf->service == NGX_CONF_UNSET) {
- if (ngx_http_server_addr(r, NULL) != NGX_OK) {
- return NGX_ERROR;
- }
c = r->connection;
+ if (ngx_connection_local_sockaddr(c, NULL, 0) != NGX_OK) {
+ return NGX_ERROR;
+ }
+
switch (c->local_sockaddr->sa_family) {
#if (NGX_HAVE_INET6)