diff options
author | pjd <pjd@FreeBSD.org> | 2006-09-13 06:58:40 +0000 |
---|---|---|
committer | pjd <pjd@FreeBSD.org> | 2006-09-13 06:58:40 +0000 |
commit | 166e57c29a09569bc76efcc5752635fc36c9c1da (patch) | |
tree | 72548a0bd3d542a45b2487e7165f00aa527227ed | |
parent | 2318032d41a56e9ffe3addaf93e0435c0cc41d6a (diff) | |
download | FreeBSD-src-166e57c29a09569bc76efcc5752635fc36c9c1da.zip FreeBSD-src-166e57c29a09569bc76efcc5752635fc36c9c1da.tar.gz |
Fix a lock leak in an error case.
Reported by: netchild
Reviewed by: rwatson
-rw-r--r-- | sys/kern/uipc_socket.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/kern/uipc_socket.c b/sys/kern/uipc_socket.c index c9da6b8..480bde8 100644 --- a/sys/kern/uipc_socket.c +++ b/sys/kern/uipc_socket.c @@ -1028,11 +1028,11 @@ sosend_dgram(so, addr, uio, top, control, flags, td) if (flags & MSG_OOB) space += 1024; space -= clen; + SOCKBUF_UNLOCK(&so->so_snd); if (resid > space) { error = EMSGSIZE; goto out; } - SOCKBUF_UNLOCK(&so->so_snd); if (uio == NULL) { resid = 0; if (flags & MSG_EOR) |