mirror of
https://github.com/apache/httpd.git
synced 2025-08-13 14:40:20 +00:00
stop using apr_sockaddr_port_get() accessor function, as it will
disappear from APR 1.0 API shortly git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@101991 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
@ -252,7 +252,7 @@ dav_lookup_result dav_lookup_uri(const char *uri, request_rec * r,
|
||||
/* now, verify that the URI uses the same scheme as the current.
|
||||
request. the port must match our port.
|
||||
*/
|
||||
apr_sockaddr_port_get(&port, r->connection->local_addr);
|
||||
port = r->connection->local_addr->port;
|
||||
if (strcasecmp(comp.scheme, scheme) != 0
|
||||
#ifdef APACHE_PORT_HANDLING_IS_BUSTED
|
||||
|| comp.port != port
|
||||
|
@ -210,8 +210,8 @@ static apr_status_t rfc1413_query(apr_socket_t *sock, conn_rec *conn,
|
||||
char user[RFC1413_USERLEN + 1]; /* XXX */
|
||||
apr_size_t buflen;
|
||||
|
||||
apr_sockaddr_port_get(&sav_our_port, conn->local_addr);
|
||||
apr_sockaddr_port_get(&sav_rmt_port, conn->remote_addr);
|
||||
sav_our_port = conn->local_addr->port;
|
||||
sav_rmt_port = conn->remote_addr->port;
|
||||
|
||||
/* send the data */
|
||||
buflen = apr_snprintf(buffer, sizeof(buffer), "%hu,%hu\r\n", sav_rmt_port,
|
||||
|
@ -1412,7 +1412,7 @@ int ap_proxy_ftp_handler(request_rec *r, proxy_server_conf *conf,
|
||||
return HTTP_INTERNAL_SERVER_ERROR;
|
||||
}
|
||||
apr_socket_addr_get(&local_addr, APR_LOCAL, sock);
|
||||
apr_sockaddr_port_get(&local_port, local_addr);
|
||||
local_port = local_addr->port;
|
||||
apr_sockaddr_ip_get(&local_ip, local_addr);
|
||||
|
||||
if ((rv = apr_socket_opt_set(local_sock, APR_SO_REUSEADDR, one))
|
||||
|
@ -244,7 +244,7 @@ static const char *alloc_listener(process_rec *process, char *addr, apr_port_t p
|
||||
ap_listen_rec *new;
|
||||
apr_port_t oldport;
|
||||
|
||||
apr_sockaddr_port_get(&oldport, sa);
|
||||
oldport = sa->port;
|
||||
/* If both ports are equivalent, then if their names are equivalent,
|
||||
* then we will re-use the existing record.
|
||||
*/
|
||||
|
@ -280,7 +280,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_sockaddr_port_get(&rport, c->remote_addr);
|
||||
rport = c->remote_addr->port;
|
||||
apr_table_addn(e, "REMOTE_PORT", apr_itoa(r->pool, rport));
|
||||
|
||||
if (r->user) {
|
||||
|
@ -913,7 +913,7 @@ static void check_hostalias(request_rec *r)
|
||||
|
||||
last_s = NULL;
|
||||
|
||||
apr_sockaddr_port_get(&port, r->connection->local_addr);
|
||||
port = r->connection->local_addr->port;
|
||||
|
||||
/* Recall that the name_chain is a list of server_addr_recs, some of
|
||||
* whose ports may not match. Also each server may appear more than
|
||||
@ -969,7 +969,7 @@ static void check_serverpath(request_rec *r)
|
||||
name_chain *src;
|
||||
apr_port_t port;
|
||||
|
||||
apr_sockaddr_port_get(&port, r->connection->local_addr);
|
||||
port = r->connection->local_addr->port;
|
||||
|
||||
/*
|
||||
* This is in conjunction with the ServerPath code in http_core, so we
|
||||
@ -1044,7 +1044,7 @@ AP_DECLARE(void) ap_update_vhost_given_ip(conn_rec *conn)
|
||||
/* maybe there's a default server or wildcard name-based vhost
|
||||
* matching this port
|
||||
*/
|
||||
apr_sockaddr_port_get(&port, conn->local_addr);
|
||||
port = conn->local_addr->port;
|
||||
|
||||
trav = find_default_server(port);
|
||||
if (trav) {
|
||||
|
Reference in New Issue
Block a user