Current-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: dhcpd build break



Valery Ushakov <uwe%stderr.spb.ru@localhost> wrote:
 |On Sat, Jun 22, 2013 at 02:32:04 +0100, Roy Marples wrote:
 |>>/build/netbsd-local/src/external/bsd/dhcpcd/dist/dhcp6.c:641:11:
 |>>error: operation on 'o->len' may be undefined
 |> 
 |> The code in question:
 |> 
 |>                         o = D6_NEXT_OPTION(o);
 |>                         o->code = htons(D6_OPTION_ORO);
 |>                         o->len = 0;
 |
 |No, the code in question is:
 |
 |    o->len = htons(++o->len);
 |
 |and since on big-endian hton* is a no-op it becomes
 |
 |    o->len = ++o->len;
 |
 |which violates C sequence point rules.

heaven, help.

 |-uwe

--steffen


Home | Main Index | Thread Index | Old Index