diff options
| author | Robert Watson <rwatson@FreeBSD.org> | 2006-06-03 19:29:26 +0000 |
|---|---|---|
| committer | Robert Watson <rwatson@FreeBSD.org> | 2006-06-03 19:29:26 +0000 |
| commit | f24618aaf0b2fd9497568ddcce2a168550040887 (patch) | |
| tree | 1a21d709ac1dbc4fffb9f1d9a4b6ef31673a0280 /sys | |
| parent | 7490082f087d5bd5226cb8a70da0e9a7d1f55e43 (diff) | |
Notes
Diffstat (limited to 'sys')
| -rw-r--r-- | sys/netinet/udp_usrreq.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/sys/netinet/udp_usrreq.c b/sys/netinet/udp_usrreq.c index 5118290e3198..84c5521f6592 100644 --- a/sys/netinet/udp_usrreq.c +++ b/sys/netinet/udp_usrreq.c @@ -962,12 +962,10 @@ udp_attach(struct socket *so, int proto, struct thread *td) inp = sotoinpcb(so); KASSERT(inp == NULL, ("udp_attach: inp != NULL")); - INP_INFO_WLOCK(&udbinfo); error = soreserve(so, udp_sendspace, udp_recvspace); - if (error) { - INP_INFO_WUNLOCK(&udbinfo); + if (error) return error; - } + INP_INFO_WLOCK(&udbinfo); error = in_pcballoc(so, &udbinfo, "udpinp"); if (error) { INP_INFO_WUNLOCK(&udbinfo); |
