From: Roy Marples Date: Wed, 29 Oct 2008 08:13:15 +0000 (+0000) Subject: ~0U is better than just ~0 for this. X-Git-Tag: v5.0.0~198 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b85bcbf82d1c0547415c76614b8730a03ff2e025;p=thirdparty%2Fdhcpcd.git ~0U is better than just ~0 for this. --- diff --git a/dhcp.c b/dhcp.c index 4c30dfca..c8631e39 100644 --- a/dhcp.c +++ b/dhcp.c @@ -537,7 +537,7 @@ decode_rfc3442_rt(int dl, const uint8_t *data) if (ocets > 0) { memcpy(&rt->dest.s_addr, p, ocets); p += ocets; - rt->net.s_addr = htonl(~0 << (32 - cidr)); + rt->net.s_addr = htonl(~0U << (32 - cidr)); } /* Finally, snag the router */