summaryrefslogtreecommitdiffstats
path: root/sys/net
diff options
context:
space:
mode:
authoremaste <emaste@FreeBSD.org>2012-07-10 20:59:35 +0000
committeremaste <emaste@FreeBSD.org>2012-07-10 20:59:35 +0000
commitb19509b9f382661b6604836db565fd7e0d9a94f3 (patch)
treeb3f466d394fa84d3dd9742498d8eddb922ad946c /sys/net
parente53b15fec4f29448c20344519738f28e159da1cc (diff)
downloadFreeBSD-src-b19509b9f382661b6604836db565fd7e0d9a94f3.zip
FreeBSD-src-b19509b9f382661b6604836db565fd7e0d9a94f3.tar.gz
Simplify error case
Submitted by: thompsa@
Diffstat (limited to 'sys/net')
-rw-r--r--sys/net/if_bridge.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/sys/net/if_bridge.c b/sys/net/if_bridge.c
index 7a57e9c..7f44bc2 100644
--- a/sys/net/if_bridge.c
+++ b/sys/net/if_bridge.c
@@ -1811,10 +1811,10 @@ bridge_enqueue(struct bridge_softc *sc, struct ifnet *dst_ifp, struct mbuf *m)
m->m_flags &= ~M_VLANTAG;
}
- if (err == 0)
- err = dst_ifp->if_transmit(dst_ifp, m);
- else
- m_freem(m);
+ if ((err = dst_ifp->if_transmit(dst_ifp, m))) {
+ m_freem(m0);
+ break;
+ }
}
if (err == 0) {
OpenPOWER on IntegriCloud