diff options
author | Ed Maste <emaste@FreeBSD.org> | 2008-08-27 17:10:37 +0000 |
---|---|---|
committer | Ed Maste <emaste@FreeBSD.org> | 2008-08-27 17:10:37 +0000 |
commit | d54d93ac7f0fa6e1cf92880507f9eac7352718dd (patch) | |
tree | dfb3be4d55a3146207e18e8e237fb3ddc270ae9c /sys/net/if_ethersubr.c | |
parent | 0d6ff382c34ca5391758d9a5ba0ebdea88daaf64 (diff) | |
download | src-d54d93ac7f0fa6e1cf92880507f9eac7352718dd.tar.gz src-d54d93ac7f0fa6e1cf92880507f9eac7352718dd.zip |
Move CTASSERT of ether header sizes out of the header file and into
if_ethersubr.c. CTASSERT is implemented using a dummy typedef, which if
used in a header file may conflict with another CTASSERT in a source file
using that header.
I'll make a note of this in CTASSERT's man page.
Approved by: imp
Notes
Notes:
svn path=/head/; revision=182285
Diffstat (limited to 'sys/net/if_ethersubr.c')
-rw-r--r-- | sys/net/if_ethersubr.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/sys/net/if_ethersubr.c b/sys/net/if_ethersubr.c index 25004b4ebcbe..d20fb65cfd8c 100644 --- a/sys/net/if_ethersubr.c +++ b/sys/net/if_ethersubr.c @@ -101,6 +101,11 @@ extern u_char aarp_org_code[3]; #include <security/mac/mac_framework.h> +#ifdef CTASSERT +CTASSERT(sizeof (struct ether_header) == ETHER_ADDR_LEN * 2 + 2); +CTASSERT(sizeof (struct ether_addr) == ETHER_ADDR_LEN); +#endif + /* netgraph node hooks for ng_ether(4) */ void (*ng_ether_input_p)(struct ifnet *ifp, struct mbuf **mp); void (*ng_ether_input_orphan_p)(struct ifnet *ifp, struct mbuf *m); |