From: Alan T. DeKok Date: Sun, 28 Jan 2024 14:20:52 +0000 (-0500) Subject: dhcp attributes can have zeeo length X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5dc36bfdb6d077c4acc2e305e16a09429ec8ec53;p=thirdparty%2Ffreeradius-server.git dhcp attributes can have zeeo length --- diff --git a/src/protocols/dhcpv4/decode.c b/src/protocols/dhcpv4/decode.c index fefefc01328..cbbecdd175d 100644 --- a/src/protocols/dhcpv4/decode.c +++ b/src/protocols/dhcpv4/decode.c @@ -619,7 +619,7 @@ ssize_t fr_dhcpv4_decode_option(TALLOC_CTX *ctx, fr_pair_list_t *out, } else { slen = decode_value(ctx, out, da, concat_buffer, q - concat_buffer, packet_ctx); } - if (slen <= 0) return slen; + if (slen < 0) return slen; /* * The actual amount of data we decoded, including the various headers.