summaryrefslogtreecommitdiffstats
path: root/sys/net/if_ethersubr.c
diff options
context:
space:
mode:
authorcjc <cjc@FreeBSD.org>2002-10-14 05:27:00 +0000
committercjc <cjc@FreeBSD.org>2002-10-14 05:27:00 +0000
commitaf56ac88c7882988e85dd8b6f853699347cd8934 (patch)
tree1c7ef4381980586bd6c114152b4331c8c5b1e4b0 /sys/net/if_ethersubr.c
parent25230d4c6a8ce0a2007e1b2694fcc4ff0869e15c (diff)
downloadFreeBSD-src-af56ac88c7882988e85dd8b6f853699347cd8934.zip
FreeBSD-src-af56ac88c7882988e85dd8b6f853699347cd8934.tar.gz
Unconditionally restore the pointer to the saved Ethernet header after
going to bridge.c:bdg_forward(). The header can be munged even if the mbuf does not /appear/ to change. PR: kern/42465 MFC after: 4 days
Diffstat (limited to 'sys/net/if_ethersubr.c')
-rw-r--r--sys/net/if_ethersubr.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/sys/net/if_ethersubr.c b/sys/net/if_ethersubr.c
index 427b6eb..6f0e1df 100644
--- a/sys/net/if_ethersubr.c
+++ b/sys/net/if_ethersubr.c
@@ -613,8 +613,6 @@ ether_input(struct ifnet *ifp, struct ether_header *eh, struct mbuf *m)
return;
}
if (bif != BDG_LOCAL) {
- struct mbuf *oldm = m ;
-
save_eh = *eh ; /* because it might change */
m = bdg_forward_ptr(m, eh, bif); /* needs forwarding */
/*
@@ -627,8 +625,7 @@ ether_input(struct ifnet *ifp, struct ether_header *eh, struct mbuf *m)
printf("bdg_forward drop MULTICAST PKT\n");
return;
}
- if (m != oldm) /* m changed! */
- eh = &save_eh ;
+ eh = &save_eh ;
}
if (bif == BDG_LOCAL
|| bif == BDG_BCAST
OpenPOWER on IntegriCloud