From: Graham Barr Date: Sun, 31 Jan 1999 21:50:45 +0000 (-0600) Subject: don't attempt connect() to bogus IP addresses X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=362d283a52a64f34b327787af60074b1bc15a3a6;p=p5sagit%2Fp5-mst-13.2.git don't attempt connect() to bogus IP addresses Message-Id: <19990131215045.A633@pobox.com> p4raw-id: //depot/perl@2743 --- diff --git a/t/lib/io_multihomed.t b/t/lib/io_multihomed.t index 3d7188b..d9b96c0 100644 --- a/t/lib/io_multihomed.t +++ b/t/lib/io_multihomed.t @@ -55,8 +55,14 @@ sub connect my($port, $addr) = unpack_sockaddr_in($_[0]); $addr = inet_ntoa($addr); #print "connect($self, $port, $addr)\n"; - print "ok 3\n" if $addr eq "10.250.230.10"; - print "ok 4\n" if $addr eq "10.250.230.12"; + if($addr eq "10.250.230.10") { + print "ok 3\n"; + return 0; + } + if($addr eq "10.250.230.12") { + print "ok 4\n"; + return 0; + } } $self->SUPER::connect(@_); }