Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!samsung!munnari.oz.au!mel.dit.csiro.au!yarra!bacchus!david From: david@bacchus.esa.oz.au (David Burren) Newsgroups: comp.unix.sysv386 Subject: Re: non-blocking accept(3I) wanted. (ISC's tcp/ip) Message-ID: <2550@bacchus.esa.oz.au> Date: 29 Apr 91 04:11:49 GMT References: <1991Apr25.135618.23478@aie.uucp> Organization: Expert Solutions Australia Lines: 23 In <1991Apr25.135618.23478@aie.uucp> hansb@aie.uucp (Hans Bayle) writes: >I have a little problem with the tcp/ip package that comes with >Interactive Unix System V 386/ix. >The manual says that when calling accept(3I) is done with the >file descriptor (in this case a socket) set to non-blocking, >that accept() will return immediately even when there are no pending >connections present on the queue. In that case it should return >EAGAIN. I isolated the problem in the two following tiny programs: I don't have ISC manuals on hand, but on my Sony NEWS (running a BSD) the error is EWOULDBLOCK. >Is this a bug in the lib, the manual or in my program? Your program looks ok, and I suspect the library should be returning EWOULDBLOCK in order to be compatible with other OSes, so my guess is the manual. _____________________________________________________________________________ David Burren [Athos] Email: david@bacchus.esa.oz.au Software Development Engineer Phone: +61 3 819 4554 Expert Solutions Australia, Hawthorn, VIC Fax: +61 3 819 5580