]> Sergey Matveev's repositories - public-inbox.git/commitdiff
lei: no Perl FileHandle for `undef' w/ ECONNRESET
authorEric Wong <e@80x24.org>
Thu, 21 Oct 2021 21:10:30 +0000 (21:10 +0000)
committerEric Wong <e@80x24.org>
Fri, 22 Oct 2021 00:54:49 +0000 (00:54 +0000)
Error reporting for recv_cmd4 methods is a bit wonky.

lib/PublicInbox/LEI.pm

index b68e526bf365e056b8044a5fc89ff7527ca75a93..43baeeb3d51c910f4bb1a61a7e3239dc994c1471 100644 (file)
@@ -1129,6 +1129,7 @@ sub event_step {
                if (scalar(@fds) == 1 && !defined($fds[0])) {
                        return if $! == EAGAIN;
                        die "recvmsg: $!" if $! != ECONNRESET;
+                       @fds = (); # for open loop below:
                }
                for (@fds) { open my $rfh, '+<&=', $_ }
                if ($buf eq '') {