[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1312755263.2908.6.camel@Thor>
Date: Sun, 07 Aug 2011 18:14:23 -0400
From: Michel Machado <michel@...irati.com.br>
To: Ben Hutchings <ben@...adent.org.uk>
Cc: netdev@...r.kernel.org
Subject: Re: include/linux/netlink.h: problem when included by an
application
> > The simplest solution that I came up was replacing sa_family_t in
> > include/linux/netlink.h to 'unsigned short' as header
> > include/linux/socket.h does for struct __kernel_sockaddr_storage
> > available to applications.
>
> Maybe we should do something like this in <linux/socket.h>:
>
> typedef unsigned short __kernel_sa_family_t;
> #ifdef __KERNEL__
> typedef __kernel_sa_family_t sa_family_t;
> #endif
>
> and then use __kernel_sa_family_t in <linux/netlink.h>.
>
> Ben.
I like this solution, it solves both struct __kernel_sockaddr_storage
in include/linux/socket.h, and struct sockaddr_nl in
include/linux/netlink.h.
[ ]'s
Michel Machado
--
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