summaryrefslogtreecommitdiff
path: root/sys/net/if.c
diff options
context:
space:
mode:
authorDavid Gwynne <dlg@cvs.openbsd.org>2015-09-10 14:06:44 +0000
committerDavid Gwynne <dlg@cvs.openbsd.org>2015-09-10 14:06:44 +0000
commit915133462a17b3152e3090f42c699a035e5b096b (patch)
tree3d3bddf40b87e2348c6a48adfb7dcdc4dc9ad8b7 /sys/net/if.c
parente1587e4188d630a330e92ff4f1d302d712bcd763 (diff)
if_put after if_get in if_input_process
Diffstat (limited to 'sys/net/if.c')
-rw-r--r--sys/net/if.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/sys/net/if.c b/sys/net/if.c
index 30c09edb91d..a295811fc33 100644
--- a/sys/net/if.c
+++ b/sys/net/if.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if.c,v 1.366 2015/09/10 13:32:19 dlg Exp $ */
+/* $OpenBSD: if.c,v 1.367 2015/09/10 14:06:43 dlg Exp $ */
/* $NetBSD: if.c,v 1.35 1996/05/07 05:26:04 thorpej Exp $ */
/*
@@ -604,8 +604,10 @@ if_input_process(void *xmq)
#if NBRIDGE > 0
if (ifp->if_bridgeport && (m->m_flags & M_PROTO1) == 0) {
m = bridge_input(ifp, m);
- if (m == NULL)
+ if (m == NULL) {
+ if_put(ifp);
continue;
+ }
}
m->m_flags &= ~M_PROTO1; /* Loop prevention */
#endif
@@ -622,6 +624,8 @@ if_input_process(void *xmq)
if (ifih == NULL)
m_freem(m);
+
+ if_put(ifp);
}
splx(s);
KERNEL_UNLOCK();