This is a live mirror of the Perl 5 development currently hosted at
https://github.com/perl/perl5
https://perl5.git.perl.org
/
perl5.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
[perl #39178] IO::Socket::connect returns wrong errno on timeout
[perl5.git]
/
ext
/
IO
/
lib
/
IO
/
Socket.pm
diff --git
a/ext/IO/lib/IO/Socket.pm
b/ext/IO/lib/IO/Socket.pm
index
fe887d4
..
5d78322
100644
(file)
--- a/
ext/IO/lib/IO/Socket.pm
+++ b/
ext/IO/lib/IO/Socket.pm
@@
-117,6
+117,7
@@
sub connect {
my $sel = new IO::Select $sock;
+ undef $!;
if (!$sel->can_write($timeout)) {
$err = $! || (exists &Errno::ETIMEDOUT ? &Errno::ETIMEDOUT : 1);
$@ = "connect: timeout";