On Thu, Oct 09, 2008 at 08:12:28AM +0200, Alexander Burger wrote: > Under Linux, select() may report a socket file descriptor as "ready > for reading", while nevertheless a subsequent read blocks. This could > for example happen when data has arrived but upon examination has > wrong checksum and is discarded. There may be other circumstances in > which a file descriptor is spuriously reported as ready. > > This is indeed be a k.o. criterion. I regarded this as a bug in Linux. > Don't know if this is still valid, and how the case is in other > operating systems.
After a lengthy discussion with Randall on the phone, he convinced me that it would be wise to change the sockets in the PicoLisp kernel to non-blocking mode in general. I'll try this out soon. It will probably involve only the removal of the blocking(YES, ex, sd2); calls in "src/net.c", and additional checks for EAGAIN after some read() calls. Does anybody see a problem with that? Cheers, - Alex -- UNSUBSCRIBE: mailto:[EMAIL PROTECTED]