diff options
Diffstat (limited to 'sys/net/if_ethersubr.c')
-rw-r--r-- | sys/net/if_ethersubr.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/sys/net/if_ethersubr.c b/sys/net/if_ethersubr.c index e8cfa0d..3a3b09a 100644 --- a/sys/net/if_ethersubr.c +++ b/sys/net/if_ethersubr.c @@ -446,8 +446,16 @@ ether_input(ifp, eh, m) m_freem(m); return; } - if (bif != BDG_LOCAL) + if (bif != BDG_LOCAL) { bdg_forward(&m, eh, bif); /* needs forwarding */ + /* + * Do not continue if bdg_forward() processed our + * packet (and cleared the mbuf pointer m) or if + * it dropped (m_free'd) the packet itself. + */ + if (m == NULL) + return; + } if (bif == BDG_LOCAL || bif == BDG_BCAST || bif == BDG_MCAST) |