May need a little work :)
#! perl -slw use strict; use threads; use Connector qw[ connect ]; my $con1 = connect( 'server1' ) or die "Couldn't connect to server1"; async{ $con1->send( "I'm alive") while sleep 2; }; my $con2; 1 until( $con2 = connect( 'server2' ) ); while( my $data = $con2->read ) { ## process $data }
In reply to Re: connect() connection timeout
by BrowserUk
in thread connect() connection timeout
by perlthirst
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |