git: 8a641f97130f - stable/15 - if_ovpn: Fix a lock leak in an error path
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Wed, 08 Jul 2026 18:09:53 UTC
The branch stable/15 has been updated by markj:
URL: https://cgit.FreeBSD.org/src/commit/?id=8a641f97130fd397c1aeffdb5addacfe5d05b0e8
commit 8a641f97130fd397c1aeffdb5addacfe5d05b0e8
Author: Mark Johnston <markj@FreeBSD.org>
AuthorDate: 2026-06-20 14:12:19 +0000
Commit: Mark Johnston <markj@FreeBSD.org>
CommitDate: 2026-07-08 18:09:34 +0000
if_ovpn: Fix a lock leak in an error path
Reviewed by: kp
MFC after: 1 week
Fixes: 04a7134c1e92 ("if_ovpn: fix use-after-free of mbuf")
Differential Revision: https://reviews.freebsd.org/D57696
(cherry picked from commit f7b71f832c990da0bf203095f02405df665529d0)
---
sys/net/if_ovpn.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/sys/net/if_ovpn.c b/sys/net/if_ovpn.c
index 7c416055e939..b4796fb95589 100644
--- a/sys/net/if_ovpn.c
+++ b/sys/net/if_ovpn.c
@@ -2517,6 +2517,7 @@ ovpn_udp_input(struct mbuf *m, int off, struct inpcb *inp,
m = m_unshare(m, M_NOWAIT);
if (m == NULL) {
+ OVPN_RUNLOCK(sc);
OVPN_COUNTER_ADD(sc, nomem_data_pkts_in, 1);
if_inc_counter(sc->ifp, IFCOUNTER_IERRORS, 1);
return (true);