diff options
author | thompsa <thompsa@FreeBSD.org> | 2012-02-23 00:59:21 +0000 |
---|---|---|
committer | thompsa <thompsa@FreeBSD.org> | 2012-02-23 00:59:21 +0000 |
commit | 51c7bc89f03c75520ffd7c33fdcbb80a9b81a614 (patch) | |
tree | dd210d8dd6e2e20989714f9fbcc00161de501819 /sys/net/if_bridge.c | |
parent | c094a4b8e20b2d1f5fc983dc23becf54066467f1 (diff) | |
download | FreeBSD-src-51c7bc89f03c75520ffd7c33fdcbb80a9b81a614.zip FreeBSD-src-51c7bc89f03c75520ffd7c33fdcbb80a9b81a614.tar.gz |
bstp_input() always consumes the packet so remove the mbuf handling dance
around it.
Obtained from: OpenBSD (r1.37)
Diffstat (limited to 'sys/net/if_bridge.c')
-rw-r--r-- | sys/net/if_bridge.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/sys/net/if_bridge.c b/sys/net/if_bridge.c index 8f9dc9c..bf00cb4 100644 --- a/sys/net/if_bridge.c +++ b/sys/net/if_bridge.c @@ -2215,11 +2215,9 @@ bridge_input(struct ifnet *ifp, struct mbuf *m) /* Tap off 802.1D packets; they do not get forwarded. */ if (memcmp(eh->ether_dhost, bstp_etheraddr, ETHER_ADDR_LEN) == 0) { - m = bstp_input(&bif->bif_stp, ifp, m); - if (m == NULL) { - BRIDGE_UNLOCK(sc); - return (NULL); - } + bstp_input(&bif->bif_stp, ifp, m); /* consumes mbuf */ + BRIDGE_UNLOCK(sc); + return (NULL); } if ((bif->bif_flags & IFBIF_STP) && |