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 retrieving revision 1.212 retrieving revision 1.213 diff -u -p -r1.212 -r1.213 --- src/sys/kern/uipc_socket.c 2012/10/08 19:20:45 1.212 +++ src/sys/kern/uipc_socket.c 2013/02/14 21:57:58 1.213 @@ -1,4 +1,4 @@ -/* $NetBSD: uipc_socket.c,v 1.212 2012/10/08 19:20:45 pooka Exp $ */ +/* $NetBSD: uipc_socket.c,v 1.213 2013/02/14 21:57:58 christos Exp $ */ /*- * Copyright (c) 2002, 2007, 2008, 2009 The NetBSD Foundation, Inc. @@ -63,7 +63,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: uipc_socket.c,v 1.212 2012/10/08 19:20:45 pooka Exp $"); +__KERNEL_RCSID(0, "$NetBSD: uipc_socket.c,v 1.213 2013/02/14 21:57:58 christos Exp $"); #include "opt_compat_netbsd.h" #include "opt_sock_counters.h" @@ -585,6 +585,8 @@ fsocreate(int domain, struct socket **so fp->f_data = so; fd_affix(curproc, fp, fd); *fdout = fd; + if (flags & SOCK_NONBLOCK) + so->so_state |= SS_NBIO; } return error; }