Mercurial > hg > dhcpcd
changeset 2191:0b05aeb7dfc6 draft
Pedantic change
| author | Roy Marples <roy@marples.name> |
|---|---|
| date | Wed, 04 Dec 2013 13:21:45 +0000 |
| parents | 2aca38b8b8bd |
| children | 11e8ddedaf22 |
| files | dhcp6.c |
| diffstat | 1 files changed, 3 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/dhcp6.c Wed Dec 04 10:48:22 2013 +0000 +++ b/dhcp6.c Wed Dec 04 13:21:45 2013 +0000 @@ -1320,7 +1320,7 @@ while ((o = dhcp6_findoption(D6_OPTION_IA_ADDR, d, l))) { l -= ((const uint8_t *)o - d); d += ((const uint8_t *)o - d); - u32 = htons(o->len); + u32 = ntohs(o->len); l -= sizeof(*o) + u32; d += sizeof(*o) + u32; if (u32 < 24) { @@ -1408,7 +1408,7 @@ while ((o = dhcp6_findoption(D6_OPTION_IAPREFIX, d, l))) { l -= ((const uint8_t *)o - d); d += ((const uint8_t *)o - d); - u32 = htons(o->len); + u32 = ntohs(o->len); l -= sizeof(*o) + u32; d += sizeof(*o) + u32; if (u32 < 25) { @@ -1492,7 +1492,7 @@ while ((o = dhcp6_findoption(ifo->ia_type, d, l))) { l -= ((const uint8_t *)o - d); d += ((const uint8_t *)o - d); - ol = htons(o->len); + ol = ntohs(o->len); l -= sizeof(*o) + ol; d += sizeof(*o) + ol; u32 = ifo->ia_type == D6_OPTION_IA_TA ? 4 : 12;
