Thread (17 messages) 17 messages, 5 authors, 2013-06-05

Re: [PATCH] include/linux/skbuff.h: using '0xffff' instead of '~0U'

From: Andy Shevchenko <hidden>
Date: 2013-05-31 21:05:13
Also in: lkml

On Thu, May 30, 2013 at 9:03 AM, Chen Gang [off-list ref] wrote:
Both 'transport_header' and 'mac_header' are u16, which are never equal
to '~0U'.

So need use '0xffff' instead of '~0U'.
Why not "(u16)~0" ?
Or even better "!= USHORT_MAX"?

Or mac_header + 1 == 0, though it less clear.

--
With Best Regards,
Andy Shevchenko
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help