From b203f64462932121672b50056302e26b69cafcd5 Mon Sep 17 00:00:00 2001 From: angelos Date: Tue, 18 Apr 2000 21:37:29 +0000 Subject: [PATCH] Remove the ethernet header from the mbuf before passing it on to bridge_input() --- sys/netinet/ip_ether.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/sys/netinet/ip_ether.c b/sys/netinet/ip_ether.c index 57c09f3a16b..97cc0ed77d6 100644 --- a/sys/netinet/ip_ether.c +++ b/sys/netinet/ip_ether.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ip_ether.c,v 1.8 2000/04/11 16:28:49 angelos Exp $ */ +/* $OpenBSD: ip_ether.c,v 1.9 2000/04/18 21:37:29 angelos Exp $ */ /* * The author of this code is Angelos D. Keromytis (kermit@adk.gr) @@ -168,9 +168,13 @@ va_dcl else m->m_flags |= M_BCAST; } + if (m->m_flags & (M_BCAST|M_MCAST)) m->m_pkthdr.rcvif->if_imcasts++; + /* Trim the beginning of the mbuf, to remove the ethernet header */ + m_adj(m, sizeof(struct ether_header)); + #if NBRIDGE > 0 /* * Tap the packet off here for a bridge, if configured and -- 2.20.1