diff options
author | sumikawa <sumikawa@FreeBSD.org> | 2001-05-20 15:33:46 +0000 |
---|---|---|
committer | sumikawa <sumikawa@FreeBSD.org> | 2001-05-20 15:33:46 +0000 |
commit | 2f599e5a3de9fdb6b3f33e8d19e72a88d394dc0f (patch) | |
tree | b1df7fda7a7f7e7b5a28af90d425ccbb363f443e /sys/netinet6/frag6.c | |
parent | d22e1f59c1dde069626cab9c0b6f23557e561ba2 (diff) | |
download | FreeBSD-src-2f599e5a3de9fdb6b3f33e8d19e72a88d394dc0f.zip FreeBSD-src-2f599e5a3de9fdb6b3f33e8d19e72a88d394dc0f.tar.gz |
Plug memoly leak in overlaps fragment cases.
Obtained from: KAME
Diffstat (limited to 'sys/netinet6/frag6.c')
-rw-r--r-- | sys/netinet6/frag6.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/sys/netinet6/frag6.c b/sys/netinet6/frag6.c index 6222e75..458a391 100644 --- a/sys/netinet6/frag6.c +++ b/sys/netinet6/frag6.c @@ -391,18 +391,24 @@ frag6_input(mp, offp, proto) i = af6->ip6af_up->ip6af_off + af6->ip6af_up->ip6af_frglen - ip6af->ip6af_off; if (i > 0) { +#if 0 /* suppress the noisy log */ log(LOG_ERR, "%d bytes of a fragment from %s " "overlaps the previous fragment\n", i, ip6_sprintf(&q6->ip6q_src)); +#endif + free(ip6af, M_FTABLE); goto dropfrag; } } if (af6 != (struct ip6asfrag *)q6) { i = (ip6af->ip6af_off + ip6af->ip6af_frglen) - af6->ip6af_off; if (i > 0) { +#if 0 /* suppress the noisy log */ log(LOG_ERR, "%d bytes of a fragment from %s " "overlaps the succeeding fragment", i, ip6_sprintf(&q6->ip6q_src)); +#endif + free(ip6af, M_FTABLE); goto dropfrag; } } |