Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. =================================================================== RCS file: /ftp/cvs/cvsroot/src/sys/kern/uipc_socket.c,v rcsdiff: /ftp/cvs/cvsroot/src/sys/kern/uipc_socket.c,v: warning: Unknown phrases like `commitid ...;' are present. retrieving revision 1.149 retrieving revision 1.151 diff -u -p -r1.149 -r1.151 --- src/sys/kern/uipc_socket.c 2007/12/05 17:19:59 1.149 +++ src/sys/kern/uipc_socket.c 2008/02/06 21:57:54 1.151 @@ -1,4 +1,4 @@ -/* $NetBSD: uipc_socket.c,v 1.149 2007/12/05 17:19:59 pooka Exp $ */ +/* $NetBSD: uipc_socket.c,v 1.151 2008/02/06 21:57:54 ad Exp $ */ /*- * Copyright (c) 2002, 2007 The NetBSD Foundation, Inc. @@ -68,7 +68,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: uipc_socket.c,v 1.149 2007/12/05 17:19:59 pooka Exp $"); +__KERNEL_RCSID(0, "$NetBSD: uipc_socket.c,v 1.151 2008/02/06 21:57:54 ad Exp $"); #include "opt_sock_counters.h" #include "opt_sosend_loan.h" @@ -580,13 +580,13 @@ sobind(struct socket *so, struct mbuf *n } int -solisten(struct socket *so, int backlog) +solisten(struct socket *so, int backlog, struct lwp *l) { int s, error; s = splsoftnet(); error = (*so->so_proto->pr_usrreq)(so, PRU_LISTEN, NULL, - NULL, NULL, NULL); + NULL, NULL, l); if (error != 0) { splx(s); return error; @@ -660,8 +660,7 @@ soclose(struct socket *so) goto drop; } if (so->so_options & SO_LINGER) { - if ((so->so_state & SS_ISDISCONNECTING) && - (so->so_state & SS_NBIO)) + if ((so->so_state & SS_ISDISCONNECTING) && so->so_nbio) goto drop; while (so->so_state & SS_ISCONNECTED) { error = tsleep((void *)&so->so_timeo, @@ -870,7 +869,7 @@ sosend(struct socket *so, struct mbuf *a snderr(EMSGSIZE); if (space < resid + clen && (atomic || space < so->so_snd.sb_lowat || space < clen)) { - if (so->so_state & SS_NBIO) + if (so->so_nbio) snderr(EWOULDBLOCK); sbunlock(&so->so_snd); error = sbwait(&so->so_snd); @@ -1110,7 +1109,7 @@ soreceive(struct socket *so, struct mbuf } if (uio->uio_resid == 0) goto release; - if ((so->so_state & SS_NBIO) || (flags & MSG_DONTWAIT)) { + if (so->so_nbio || (flags & MSG_DONTWAIT)) { error = EWOULDBLOCK; goto release; }