git: de8a68da8cee - stable/15 - ipsec: Free entire mbuf chain on failure
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Thu, 09 Jul 2026 16:10:04 UTC
The branch stable/15 has been updated by emaste:
URL: https://cgit.FreeBSD.org/src/commit/?id=de8a68da8ceea284c9b6f07690d285b0931f98a3
commit de8a68da8ceea284c9b6f07690d285b0931f98a3
Author: Ed Maste <emaste@FreeBSD.org>
AuthorDate: 2026-06-05 20:51:48 +0000
Commit: Ed Maste <emaste@FreeBSD.org>
CommitDate: 2026-07-09 16:09:35 +0000
ipsec: Free entire mbuf chain on failure
Reviewed by: kib
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D57475
(cherry picked from commit 85195c0c7f8a2926f0ba131178d9231bc33c81b5)
---
sys/netipsec/ipsec_output.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/sys/netipsec/ipsec_output.c b/sys/netipsec/ipsec_output.c
index b394ff81d9c6..18a25c0feeff 100644
--- a/sys/netipsec/ipsec_output.c
+++ b/sys/netipsec/ipsec_output.c
@@ -462,7 +462,7 @@ ipsec4_common_output(struct ifnet *ifp, struct mbuf *m, struct inpcb *inp,
if (((m->m_flags & M_PKTHDR) != 0 && m->m_pkthdr.len < sizeof(*ip)) ||
((m->m_flags & M_PKTHDR) == 0 && m->m_len < sizeof(*ip))) {
- m_free(m);
+ m_freem(m);
return (EACCES);
}
if (ip1 != NULL) {