]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
look at variable, not parent flag.
authorAlan T. DeKok <aland@freeradius.org>
Wed, 23 Oct 2019 02:17:11 +0000 (22:17 -0400)
committerAlan T. DeKok <aland@freeradius.org>
Wed, 23 Oct 2019 02:17:11 +0000 (22:17 -0400)
which is still correct, and which also shuts up the static
analyzer

src/protocols/dhcpv6/encode.c

index a89fc6d5e9c4c697cbedf440893a1635d6375989..b3a896392f23d0883ec164ec061bb95bcb91cccb 100644 (file)
@@ -507,8 +507,8 @@ static inline ssize_t encode_array(uint8_t *out, size_t outlen,
                /*
                 *      Populate the length field
                 */
-               if (!da->flags.length) *len_field = htons((uint16_t) slen);
-
+               if (len_field) *len_field = htons((uint16_t) slen);
+               
                vp = fr_cursor_current(cursor);
                if (!vp || (vp->da != da)) break;               /* Stop if we have an attribute of a different type */
        }