]> git.decadent.org.uk Git - odhcp6c.git/commitdiff
Also test for correct IA-ID for IA_NA
authorSteven Barth <steven@midlink.org>
Fri, 22 Aug 2014 14:09:34 +0000 (16:09 +0200)
committerSteven Barth <steven@midlink.org>
Fri, 22 Aug 2014 14:09:34 +0000 (16:09 +0200)
src/dhcpv6.c

index e52fd6cd95fcf5dc4aa47febb023cb12e00b8eca..aafd237b034b4a9bd187eb100f88382a3d0ee23a 100644 (file)
@@ -934,7 +934,7 @@ static int dhcpv6_handle_reply(enum dhcpv6_msg orig, _unused const int rc,
                        struct dhcpv6_ia_hdr *ia_hdr = (void*)(&odata[-4]);
 
                        // Test ID
-                       if (ia_hdr->iaid != 1 && otype == DHCPV6_OPT_IA_NA)
+                       if (ia_hdr->iaid != htonl(1) && otype == DHCPV6_OPT_IA_NA)
                                continue;
 
                        uint16_t code = DHCPV6_Success;