This is the mail archive of the
cygwin@sourceware.cygnus.com
mailing list for the Cygwin project.
Re: Non blocking I/O
- To: Mike Bernson <mike at mbsun dot mlb dot org>
- Subject: Re: Non blocking I/O
- From: Holister <wfire at pimpz dot darkillustrated dot org>
- Date: Sat, 17 May 1997 22:19:55 -0400 (EDT)
- cc: gnu-win32 at cygnus dot com
On Sat, 17 May 1997, Mike Bernson wrote:
> I am trying to set the the non-block read or write for a
> tcp-socket.
>
> I do the following fcntl(fd, SETFL, O_NONBLOCK) which does not
> return any errors. Then a do a read on the fd and it blocks.
>
> I need a way to do none blocking reads or find out how much data
> is pending so I can do the read for just that amount of data.
>
> The same would be nice for writes but not needed.
select() will tell you IF data is pending, which is good... fctl()
doesn't work in linux for setting non_blocking on tcp sockets either...so
don't feel bad :)
-
For help on using this list (especially unsubscribing), send a message to
"gnu-win32-request@cygnus.com" with one line of text: "help".