[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Blocking/Non-Blocking Sockets and Daemons
- To: tech_(_at_)_openbsd_(_dot_)_org
- Subject: Re: Blocking/Non-Blocking Sockets and Daemons
- From: Daniel Hartmeier <daniel_(_at_)_benzedrine_(_dot_)_cx>
- Date: Sun, 25 Nov 2001 01:15:09 +0100
On Fri, Nov 23, 2001 at 03:54:16PM -0800, Randall Gellens wrote:
> I'm very confused.
> Why does this behave differently on OpenBSD than on Solaris or Linux?
> Why does fcntl() always show that O_NONBLOCK is not set, even when
> the file descriptor acts non-blocking?
I can confirm the behavior you describe, though I can't tell why this is
so, or what's wrong. It looks like the socket returned by the (async)
accept() call somehow inherits the non-blocking flag from the listening
socket, but fcntl() doesn't see it. I might miss something, but it looks
strange to me as well. I'll try to find out more about it.
Visit your host, monkey.org