summaryrefslogtreecommitdiffstats
path: root/server/util_script.c
diff options
context:
space:
mode:
Diffstat (limited to 'server/util_script.c')
-rw-r--r--server/util_script.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/server/util_script.c b/server/util_script.c
index e311d7f5cb..b3b3593ded 100644
--- a/server/util_script.c
+++ b/server/util_script.c
@@ -173,7 +173,6 @@ AP_DECLARE(void) ap_add_common_vars(request_rec *r)
const apr_table_entry_t *hdrs = (const apr_table_entry_t *) hdrs_arr->elts;
int i;
apr_port_t rport;
- apr_sockaddr_t *remotesa;
/* use a temporary apr_table_t which we'll overlap onto
* r->subprocess_env later
@@ -273,8 +272,7 @@ AP_DECLARE(void) ap_add_common_vars(request_rec *r)
apr_table_addn(e, "SERVER_ADMIN", s->server_admin); /* Apache */
apr_table_addn(e, "SCRIPT_FILENAME", r->filename); /* Apache */
- apr_socket_addr_get(&remotesa, APR_REMOTE, c->client_socket);
- apr_sockaddr_port_get(&rport, remotesa);
+ apr_sockaddr_port_get(&rport, c->remote_addr);
apr_table_addn(e, "REMOTE_PORT", apr_psprintf(r->pool, "%d", rport));
if (r->user) {