From 4b2a151dba5d4d95104e374323f36ed02f52034f Mon Sep 17 00:00:00 2001 From: Henning Brauer Date: Tue, 29 May 2007 20:31:39 +0000 Subject: now i get my hands dirty in here... from if_ethersubr.c: there was code inside #if NPF > 0 to prevent feeding back the mbuf do looutput if we are on simplex interfaces and the packet has been routed by pf, which can lead to a loop in weird corner cases. apparently nobody triggered these cases in ages, since pf.h was not included and thus NPF not defined and thus this code not compiled. --- sys/net/if_fddisubr.c | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/sys/net/if_fddisubr.c b/sys/net/if_fddisubr.c index f0180182293..8b22ec2e204 100644 --- a/sys/net/if_fddisubr.c +++ b/sys/net/if_fddisubr.c @@ -1,4 +1,4 @@ -/* $OpenBSD: if_fddisubr.c,v 1.50 2006/12/07 18:15:29 reyk Exp $ */ +/* $OpenBSD: if_fddisubr.c,v 1.51 2007/05/29 20:31:38 henning Exp $ */ /* $NetBSD: if_fddisubr.c,v 1.5 1996/05/07 23:20:21 christos Exp $ */ /* @@ -203,14 +203,9 @@ fddi_output(ifp0, m0, dst, rt0) if (!arpresolve(ac, rt, m, dst, edst)) return (0); /* if not yet resolved */ /* If broadcasting on a simplex interface, loopback a copy */ - if ((m->m_flags & M_BCAST) && (ifp->if_flags & IFF_SIMPLEX)) { -#if NPF > 0 - struct pf_mtag *t; - - if ((t = pf_find_mtag(m)) == NULL || !t->routed) -#endif + if ((m->m_flags & M_BCAST) && (ifp->if_flags & IFF_SIMPLEX) && + !m->m_pkthdr.pf.routed) mcopy = m_copy(m, 0, (int)M_COPYALL); - } type = htons(ETHERTYPE_IP); break; #endif -- cgit v1.2.3