lkml.org 
[lkml]   [2003]   [Mar]   [27]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectNetlink alignment macro
Hi

include/linux/netlink.h says: #define NLMSG_ALIGNTO 4

I think NLMSG_ALIGNTO should be 8 because the data may be a
struct containing a 64 bit member which requires 64 bit
alignment. In this case NLMSG_DATA will not work properly if
NLMSG_LENGTH(0) % 8 != 0.

Currently this is a "theoretical" issue as
sizeof(struct nlmsghdr) == 16.

Do you agree that the definition of NLMSG_ALIGNTO should
be changed?


Regards,

Thomas

PS: Please CC to my private e-mail address as I'm currently
not subscribed.

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:34    [W:0.070 / U:0.100 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site