No such thing as a small change | |
PerlMonks |
Re: Re: Non blocking read on a filehandleby c-era (Curate) |
on Jan 30, 2001 at 21:42 UTC ( [id://55290]=note: print w/replies, xml ) | Need Help?? |
You set $timeout to 0, this will cause select to block until it can read, it doesn't set select to nonblocking like you sugested. You can set $timeout to 1 and then select will wait up to 1 second to see if anything comes in, and then will continue on with the next line of code. But, this will slow down your program as it will wait up to 1 second each time your loop is run.
In Section
Seekers of Perl Wisdom
|
|