From: Todd C. Miller Date: Fri, 16 Feb 2007 11:26:45 +0000 (-0800) Subject: [perl #41521] Fix for IO::Socket send method X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=775363361efe12fcd655ebed0ffc834e50893684;p=p5sagit%2Fp5-mst-13.2.git [perl #41521] Fix for IO::Socket send method From: "Todd C. Miller" (via RT) Message-ID: p4raw-id: //depot/perl@30332 --- diff --git a/ext/IO/lib/IO/Socket.pm b/ext/IO/lib/IO/Socket.pm index 5d78322..9095093 100644 --- a/ext/IO/lib/IO/Socket.pm +++ b/ext/IO/lib/IO/Socket.pm @@ -250,7 +250,7 @@ sub send { my $peer = $_[3] || $sock->peername; croak 'send: Cannot determine peer address' - unless($peer); + unless(defined $peer); my $r = defined(getpeername($sock)) ? send($sock, $_[1], $flags)