aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMateusz Guzik <mjg@FreeBSD.org>2012-06-08 08:04:51 +0000
committerMateusz Guzik <mjg@FreeBSD.org>2012-06-08 08:04:51 +0000
commit3b5da8d609d1ba2991bc88c59aff2c664deec523 (patch)
tree431047c1149519d1288c4ca1aa595df800575ec3
parentc18783f21969632e608fb195c5e0636ba8100ce7 (diff)
downloadsrc-3b5da8d609d1ba2991bc88c59aff2c664deec523.tar.gz
src-3b5da8d609d1ba2991bc88c59aff2c664deec523.zip
Plug socket refcount leak on error in sys_sctp_peeloff.
Reviewed by: tuexen Approved by: trasz (mentor) MFC after: 3 days
Notes
Notes: svn path=/head/; revision=236738
-rw-r--r--sys/kern/uipc_syscalls.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/kern/uipc_syscalls.c b/sys/kern/uipc_syscalls.c
index a0794b989878..719d298cc568 100644
--- a/sys/kern/uipc_syscalls.c
+++ b/sys/kern/uipc_syscalls.c
@@ -2327,11 +2327,11 @@ sys_sctp_peeloff(td, uap)
goto done2;
if (head->so_proto->pr_protocol != IPPROTO_SCTP) {
error = EOPNOTSUPP;
- goto done2;
+ goto done;
}
error = sctp_can_peel_off(head, (sctp_assoc_t)uap->name);
if (error)
- goto done2;
+ goto done;
/*
* At this point we know we do have a assoc to pull
* we proceed to get the fd setup. This may block