Provide IA_MASKSIN() macro similar to IA_SIN() and IA_DSTSIN().

This commit is contained in:
Gleb Smirnoff 2012-01-08 17:20:29 +00:00
parent c82c34b4a9
commit d294536082
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=229815

View File

@ -85,6 +85,7 @@ struct in_aliasreq {
*/
#define IA_SIN(ia) (&(((struct in_ifaddr *)(ia))->ia_addr))
#define IA_DSTSIN(ia) (&(((struct in_ifaddr *)(ia))->ia_dstaddr))
#define IA_MASKSIN(ia) (&(((struct in_ifaddr *)(ia))->ia_sockmask))
#define IN_LNAOF(in, ifa) \
((ntohl((in).s_addr) & ~((struct in_ifaddr *)(ifa)->ia_subnetmask))