On Tue, 28 Mar 2006 gwtmp01 / mac.com wrote:

>
> On Mar 27, 2006, at 6:11 PM, ara.t.howard / noaa.gov wrote:
>
>
>>     STDIN.wait unless STDIN.ready?
>
> I might be missing something here but couldn't another thread
> read any pending input after STDIN.ready? has returned true and
> before STIN.wait is called?  That would result in STDIN.wait
> blocking for more input, correct?

sort of - STDIN.wait simply returns when a read from the io would not block,
so having input OR being at the end of file, for example, might cause it to
return.  thread safety must indeed be handled too.

-a
-- 
share your knowledge.  it's a way to achieve immortality.
- h.h. the 14th dali lama