]> git.ipfire.org Git - thirdparty/dhcp.git/commitdiff
Option buffer length miscalculated
authorTed Lemon <source@isc.org>
Wed, 12 Jun 1996 23:50:44 +0000 (23:50 +0000)
committerTed Lemon <source@isc.org>
Wed, 12 Jun 1996 23:50:44 +0000 (23:50 +0000)
common/options.c
options.c

index 592a11197185b5065d6c53e21e07216263ea1054..f3344bd76bbbfaabccbc119649b4c6f020f0c3af 100644 (file)
@@ -65,7 +65,7 @@ void parse_options (packet)
        /* Go through the options field, up to the end of the packet
           or the End field. */
        parse_option_buffer (packet, &packet -> raw -> options [4],
-                            packet -> packet_length - DHCP_FIXED_NON_UDP + 4);
+                            packet -> packet_length - DHCP_FIXED_NON_UDP - 4);
        /* If we parsed a DHCP Option Overload option, parse more
           options out of the buffer(s) containing them. */
        if (packet -> options_valid
index 592a11197185b5065d6c53e21e07216263ea1054..f3344bd76bbbfaabccbc119649b4c6f020f0c3af 100644 (file)
--- a/options.c
+++ b/options.c
@@ -65,7 +65,7 @@ void parse_options (packet)
        /* Go through the options field, up to the end of the packet
           or the End field. */
        parse_option_buffer (packet, &packet -> raw -> options [4],
-                            packet -> packet_length - DHCP_FIXED_NON_UDP + 4);
+                            packet -> packet_length - DHCP_FIXED_NON_UDP - 4);
        /* If we parsed a DHCP Option Overload option, parse more
           options out of the buffer(s) containing them. */
        if (packet -> options_valid