The branch main has been updated by emaste:

URL: 
https://cgit.FreeBSD.org/src/commit/?id=85195c0c7f8a2926f0ba131178d9231bc33c81b5

commit 85195c0c7f8a2926f0ba131178d9231bc33c81b5
Author:     Ed Maste <[email protected]>
AuthorDate: 2026-06-05 20:51:48 +0000
Commit:     Ed Maste <[email protected]>
CommitDate: 2026-06-06 12:35:47 +0000

    ipsec: Free entire mbuf chain on failure
    
    Reviewed by:    kib
    Sponsored by:   The FreeBSD Foundation
    Differential Revision: https://reviews.freebsd.org/D57475
---
 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) {

Reply via email to