about summary refs log tree commit homepage
path: root/lib/PublicInbox/Xapcmd.pm
diff options
context:
space:
mode:
Diffstat (limited to 'lib/PublicInbox/Xapcmd.pm')
-rw-r--r--lib/PublicInbox/Xapcmd.pm6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/PublicInbox/Xapcmd.pm b/lib/PublicInbox/Xapcmd.pm
index 8e2b9063..337978bd 100644
--- a/lib/PublicInbox/Xapcmd.pm
+++ b/lib/PublicInbox/Xapcmd.pm
@@ -142,7 +142,11 @@ sub process_queue {
                 while (scalar keys %pids) {
                         my $pid = waitpid(-1, 0);
                         my $args = delete $pids{$pid};
-                        die join(' ', @$args)." failed: $?\n" if $?;
+                        if ($args) {
+                                die join(' ', @$args)." failed: $?\n" if $?;
+                        } else {
+                                warn "unknown PID($pid) reaped: $?\n";
+                        }
                 }
         }
 }