IO::Socket help needed ... 
Author Message
 IO::Socket help needed ...

Hi,
  Can anyone tell me how to program sockets in perl so that I can tell
if the other side has connected/disconnected and avoid{*filter*} or
blocking on ports ? I use sybperl which can test database connections
with $status=$dbh->DBDEAD .. is there anything like this that can give
a 1/0 return code for socket availability ?

Thanks,
Antony.

Sent via Deja.com http://www.*-*-*.com/
Before you buy.



Mon, 24 Jun 2002 03:00:00 GMT  
 IO::Socket help needed ...


Quote:
>Hi,
>  Can anyone tell me how to program sockets in perl so that I can tell
>if the other side has connected/disconnected and avoid{*filter*} or
>blocking on ports ? I use sybperl which can test database connections
>with $status=$dbh->DBDEAD .. is there anything like this that can give
>a 1/0 return code for socket availability ?

Since you are using IO::Socket there is only a little step into also
using IO::Select. Using IO::Select you can avoid blocking. The
examples in these modules are very good.

  Lars

------------------------------

http://www.*-*-*.com/ ~matlg

Check out the Perl search utility findgrep at:
http://www.*-*-*.com/



Mon, 24 Jun 2002 03:00:00 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. Need help with IO::Socket

2. Needs help with IO::Socket und Net::Ident.

3. IO::Socket / IO::Select Help...

4. Proper way to close an IO::Socket or IO::Socket::INET

5. IO::Socket, IO::Select, and buffered/unbuffered IO

6. Help with creating UDP sockets using IO::Socket

7. ActivePerl, Win2K, non-blocking, IO::Socket, IO::Select

8. question about io::socket & io:select

9. IO::Select and IO::Socket question: multiple connections

10. IO::Socket && IO::Select Problem

11. IO::Select and IO::Socket question: multiple connections

12. IO::Select and IO::Socket

 

 
Powered by phpBB® Forum Software