Jeff Putsch (putsch / mxim.com) wrote:
>  Howdy,
>  
>  I'm trying to use select() with Open3.popen3 on Solaris 8 with ruby 1.6.7.
>  If it matters ruby was built on Solaris 2.6.
>  
>  It seems that select() is claiming file descriptors are ready whether or
>  not they are.

What you describe is actually normal behavior for select().

If select() returns a ready file descriptor and read() returns zero
bytes, this indicates an EOF condition (think of EOF as a zero-length
block of data that can be read).

In Ruby, testing for io.eof? should also work to distinguish between
real data and an EOF.

[...]

			Reimer Behrends