From: claudio Date: Fri, 8 Dec 2017 21:59:05 +0000 (+0000) Subject: Use m_freem() in error case. Found by Maxime Villard X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=85464cee49a39cdc050fb5c3822e8773fb184a91;p=openbsd Use m_freem() in error case. Found by Maxime Villard OK bluhm@ --- diff --git a/sys/netmpls/mpls_input.c b/sys/netmpls/mpls_input.c index 20c395e44be..c7b5c0d4a15 100644 --- a/sys/netmpls/mpls_input.c +++ b/sys/netmpls/mpls_input.c @@ -1,4 +1,4 @@ -/* $OpenBSD: mpls_input.c,v 1.63 2017/12/08 21:56:22 claudio Exp $ */ +/* $OpenBSD: mpls_input.c,v 1.64 2017/12/08 21:59:05 claudio Exp $ */ /* * Copyright (c) 2008 Claudio Jeker @@ -313,7 +313,7 @@ mpls_ip_adjttl(struct mbuf *m, u_int8_t ttl) } /* make sure we have a valid header */ if (in_cksum(m, hlen) != 0) { - m_free(m); + m_freem(m); return NULL; }