Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number
 
PerlMonks  

Re^2: What makes IO::Select::can_read return?

by sleepingsquirrel (Hermit)
on Feb 01, 2005 at 23:16 UTC ( #427090=note: print w/ replies, xml ) Need Help??


in reply to Re: What makes IO::Select::can_read return?
in thread What makes IO::Select::can_read return?

Run the program below and do a kill -USR1, to see it in action.

#!/usr/bin/perl -w use IO::Select; my $sel = new IO::Select (\*STDIN); $SIG{USR1} = sub { print "signal\n"}; if (my @socks = $sel->can_read(50)) { warn "Got Here\n"; } else { warn "Else: $!\n"; }


-- All code is 100% tested and functional unless otherwise noted.


Comment on Re^2: What makes IO::Select::can_read return?
Select or Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://427090]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others having an uproarious good time at the Monastery: (8)
As of 2014-09-17 20:39 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    How do you remember the number of days in each month?











    Results (99 votes), past polls