MFC: Sync new socket nonblocking/async state with file flags in accept()

Tor.Egge at cvsup.no.freebsd.org Tor.Egge at cvsup.no.freebsd.org
Mon Apr 7 11:06:51 PDT 2003


> Is this MFC needed in RELENG_4 ?

Yes.  It fixes a problem triggered by the mysql ports when compiled
with the build option WITH_LINUXTHREADS=yes.

> I ran the PR 1775 test program on FreeBSD 3.4, 4.2, 4.3, 4.7 with
> the same result:

The test program is incomplete.  

mysql changes the listen socket to nonblocking state after the
select() but before the accept().  Without this MFC, the file flags
will indicate that the new socket is nonblocking but read() will still
block.

- Tor Egge


More information about the freebsd-stable mailing list