in reply to IO::Socket *always* making connection?

IO::Socket::INET doesn't die if the connection isn't made. So, $@ wouldn't be set, even if you're in an eval. Maybe you should check to see if $socketA is defined or not ...

Being right, does not endow the right to be rude; politeness costs nothing.
Being unknowing, is not the same as being stupid.
Expressing a contrary opinion, whether to the individual or the group, is more often a sign of deeper thought than of cantankerous belligerence.
Do not mistake your goals as the only goals; your opinion as the only opinion; your confidence as correctness. Saying you know better is not the same as explaining you know better.

  • Comment on Re: IO::Socket *always* making connection?

Replies are listed 'Best First'.
Re^2: IO::Socket *always* making connection?
by wolfger (Deacon) on Feb 08, 2005 at 19:58 UTC

    Thanks for the reply. That was a good tip about eval (which I never used before), but that didn't solve my problem. I've rewritten the original post to try to be clearer, as well as getting rid of the evals.


    --
    Linux, sci-fi, and Nat Torkington, all at Penguicon 3.0
    perl -e 'print(map(chr,(0x4a,0x41,0x50,0x48,0xa)))'