From: Hans Dedecker Date: Fri, 11 Jan 2019 09:16:54 +0000 (+0100) Subject: dhcpv6: set cnt to correct IOV enum X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=b079733bee3a616c765383be35656693627716be;p=oweals%2Fodhcp6c.git dhcpv6: set cnt to correct IOV enum Make the code less error prone by setting cnt to IOV_HDR_IA_NA when sending an INFORMATION REQUEST message Signed-off-by: Hans Dedecker --- diff --git a/src/dhcpv6.c b/src/dhcpv6.c index 4cb4878..857cbe1 100644 --- a/src/dhcpv6.c +++ b/src/dhcpv6.c @@ -498,7 +498,7 @@ static void dhcpv6_send(enum dhcpv6_msg type, uint8_t trid[3], uint32_t ecs) size_t cnt = IOV_TOTAL; if (type == DHCPV6_MSG_INFO_REQ) - cnt = 8; + cnt = IOV_HDR_IA_NA; // Disable IAs if not used if (type != DHCPV6_MSG_SOLICIT && ia_na_len == 0)