]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
Use correct VP for port information
authorAlan T. DeKok <aland@freeradius.org>
Sun, 26 Jul 2015 12:02:25 +0000 (08:02 -0400)
committerAlan T. DeKok <aland@freeradius.org>
Sun, 26 Jul 2015 12:02:25 +0000 (08:02 -0400)
src/main/process.c

index f138448c29cf6a2568143947f787ee6fdbc17624..04b96c3631a62ff8b1e512cca4d1aad34aa4f7f5 100644 (file)
@@ -2800,7 +2800,6 @@ static int request_will_proxy(REQUEST *request)
                 */
        } else if (((vp = fr_pair_find_by_num(request->config, PW_PACKET_DST_IP_ADDRESS, 0, TAG_ANY)) != NULL) ||
                   ((vp = fr_pair_find_by_num(request->config, PW_PACKET_DST_IPV6_ADDRESS, 0, TAG_ANY)) != NULL)) {
-               VALUE_PAIR *port;
                uint16_t dst_port;
                fr_ipaddr_t dst_ipaddr;
 
@@ -2816,8 +2815,8 @@ static int request_will_proxy(REQUEST *request)
                        dst_ipaddr.prefix = 128;
                }
 
-               port = fr_pair_find_by_num(request->config, PW_PACKET_DST_PORT, 0, TAG_ANY);
-               if (!port) {
+               vp = fr_pair_find_by_num(request->config, PW_PACKET_DST_PORT, 0, TAG_ANY);
+               if (!vp) {
                        if (request->packet->code == PW_CODE_ACCESS_REQUEST) {
                                dst_port = PW_AUTH_UDP_PORT;