summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
Diffstat (limited to 'sys')
-rw-r--r--sys/net/pf.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/sys/net/pf.c b/sys/net/pf.c
index d7327444372..3e27052b301 100644
--- a/sys/net/pf.c
+++ b/sys/net/pf.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pf.c,v 1.94 2001/07/02 19:18:40 provos Exp $ */
+/* $OpenBSD: pf.c,v 1.95 2001/07/02 19:19:49 provos Exp $ */
/*
* Copyright (c) 2001, Daniel Hartmeier
@@ -1280,8 +1280,10 @@ pf_send_icmp(struct mbuf *m, u_int8_t type, u_int8_t code)
if (mtag == NULL)
return;
m0 = m_copy(m, 0, M_COPYALL);
- if (m0 == NULL)
+ if (m0 == NULL) {
+ m_tag_free(mtag);
return;
+ }
m_tag_prepend(m0, mtag);
icmp_error(m0, type, code, 0, 0);
}