From d274e6b6411bddf127777c1880d06d5e8e534cd4 Mon Sep 17 00:00:00 2001 From: Max Laier Date: Mon, 23 May 2005 17:07:16 +0000 Subject: [PATCH] Fix semantics of ph_busy_count == -1 to pass instead of block. PR: kern/81128 Submitted by: Joost Bekkers MFC-after: 2 weeks --- sys/net/pfil.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/sys/net/pfil.c b/sys/net/pfil.c index c9b7ce7acce..35ac338095b 100644 --- a/sys/net/pfil.c +++ b/sys/net/pfil.c @@ -119,12 +119,14 @@ pfil_run_hooks(struct pfil_head *ph, struct mbuf **mp, struct ifnet *ifp, struct mbuf *m = *mp; int rv = 0; + if (ph->ph_busy_count == -1) + return (0); /* * Prevent packet filtering from starving the modification of * the packet filters. We would prefer a reader/writer locking * mechanism with guaranteed ordering, though. */ - if (ph->ph_busy_count == -1 || ph->ph_want_write) { + if (ph->ph_want_write) { m_freem(*mp); *mp = NULL; return (ENOBUFS);