|author||David S. Miller <firstname.lastname@example.org>||2011-08-07 22:48:07 -0700|
|committer||David S. Miller <email@example.com>||2011-08-07 22:48:07 -0700|
|parent||ipv4: Fix ip_getsockopt for IP_PKTOPTIONS (diff)|
net: Make userland include of netlink.h more sane.
Currently userland will barf when including linux/netlink.h unless it precisely includes sys/socket.h first. The issue is where the definition of "sa_family_t" comes from. We've been back and forth on how to fix this issue in the past, see: http://thread.gmane.org/gmane.linux.debian.devel.bugs.general/622621 http://thread.gmane.org/gmane.linux.network/143380 Ben Hutchings suggested we take a hint from how we handle the sockaddr_storage type. First we define a "__kernel_sa_family_t" to linux/socket.h that is always defined. Then if __KERNEL__ is defined, we also define "sa_family_t" as equal to "__kernel_sa_family_t". Then in places like linux/netlink.h we use __kernel_sa_family_t in user visible datastructures. Reported-by: Michel Machado <firstname.lastname@example.org> Signed-off-by: David S. Miller <email@example.com>
Diffstat (limited to 'net')
0 files changed, 0 insertions, 0 deletions