summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authornp <np@FreeBSD.org>2012-11-16 00:21:54 +0000
committernp <np@FreeBSD.org>2012-11-16 00:21:54 +0000
commit33f46cf89f0cc92752f73e4347c3bf1cf4e9f320 (patch)
treed9978c98cffdd1afdc687d47a95f8df4936f00a0
parent609262549022c7dfc242fe62691faea879f1a2e7 (diff)
downloadFreeBSD-src-33f46cf89f0cc92752f73e4347c3bf1cf4e9f320.zip
FreeBSD-src-33f46cf89f0cc92752f73e4347c3bf1cf4e9f320.tar.gz
cxgbe/tom: Plug mbuf leak.
MFC after: 3 days
-rw-r--r--sys/dev/cxgbe/tom/t4_listen.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/sys/dev/cxgbe/tom/t4_listen.c b/sys/dev/cxgbe/tom/t4_listen.c
index 05d11b3..84cd1a2 100644
--- a/sys/dev/cxgbe/tom/t4_listen.c
+++ b/sys/dev/cxgbe/tom/t4_listen.c
@@ -559,8 +559,10 @@ t4_syncache_respond(struct toedev *tod, void *arg, struct mbuf *m)
struct tcphdr *th = (void *)(ip + 1);
wr = (struct wrqe *)atomic_readandclear_ptr(&synqe->wr);
- if (wr == NULL)
+ if (wr == NULL) {
+ m_freem(m);
return (EALREADY);
+ }
bzero(&to, sizeof(to));
tcp_dooptions(&to, (void *)(th + 1), (th->th_off << 2) - sizeof(*th),
OpenPOWER on IntegriCloud