]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
we don't care about the results of dhcpv4_decode
authorAlan T. DeKok <aland@freeradius.org>
Sun, 19 Nov 2023 12:56:50 +0000 (07:56 -0500)
committerAlan T. DeKok <aland@freeradius.org>
Sun, 19 Nov 2023 12:56:50 +0000 (07:56 -0500)
and print the correct pair list we just decoded :(

src/bin/dhcpclient.c

index a7c5c43f70f6831a96e69d8efa502d399778264e..f568c11a61f662838e3f90e39de7a2d367aeefaf 100644 (file)
@@ -709,13 +709,14 @@ int main(int argc, char **argv)
        }
 
        /*
-        *      Decode to produce fr_pair_ts from the default field
+        *      Decode the request to produce fr_pair_t's from the headers.
         */
        if (fr_debug_lvl) {
                if (fr_debug_lvl > 1) fr_dhcpv4_print_hex(stdout, packet->data, packet->data_len);
 
-               fr_dhcpv4_decode(packet, &reply_vps, packet->data, packet->data_len, &packet->code);
-               dhcp_packet_debug(packet, &packet_vps, false);
+               (void) fr_dhcpv4_decode(packet, &reply_vps, packet->data, packet->data_len, &packet->code);
+               dhcp_packet_debug(packet, &reply_vps, false);
+               fr_pair_list_free(&reply_vps);
        }
 
 #ifdef HAVE_LIBPCAP