For example:
Hope you find this useful.use IO::Select; $s = IO::Select->new(); $s->add(\*STDIN); if ($s->can_read(0)) { # Non-blocking check. # Something to read! } else { # Nothing to read. }
Cheers,
Paul
In reply to Re: nonblocking io
by pjf
in thread nonblocking io
by smackdab
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |