[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <AE90C24D6B3A694183C094C60CF0A2F6026B6EF4@saturn3.aculab.com>
Date: Wed, 25 Apr 2012 15:57:39 +0100
From: "David Laight" <David.Laight@...LAB.COM>
To: "David Laight" <David.Laight@...LAB.COM>,
"Antonio Quartulli" <ordex@...istici.org>, <davem@...emloft.net>
Cc: <netdev@...r.kernel.org>, <b.a.t.m.a.n@...ts.open-mesh.org>
Subject: RE: [PATCH 03/15] batman-adv: add biggest_unsigned_int(x) macro
> > +/* Returns the biggest unsigned integer with the sizeof x */
> > +#define biggest_unsigned_int(x) (~(x)0)
>
> Nope - biggest_unsigned_int(unsigned char) is probably 0xffffffff
To correct myself, it is actually ((int)(-1)) (ie a signed value).
David
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists