X-Git-Url: http://www.git.stargrave.org/?a=blobdiff_plain;f=xt%2Fcreate-many-inboxes.t;h=f44334cce6dd9e383c5168ea24980725d7a85f81;hb=bf367c9ac999e2e64a53ead083f68b171d9f6d35;hp=c92643b2d33eb26a803113a0fc1231ad50e94275;hpb=8862c33ae93eea1af6246cd3c7a81e0a122186bf;p=public-inbox.git
diff --git a/xt/create-many-inboxes.t b/xt/create-many-inboxes.t
index c92643b2..f44334cc 100644
--- a/xt/create-many-inboxes.t
+++ b/xt/create-many-inboxes.t
@@ -1,5 +1,5 @@
#!perl -w
-# Copyright (C) 2020 all contributors
+# Copyright (C) 2020-2021 all contributors
# License: AGPL-3.0+
use strict;
use Test::More;
@@ -68,7 +68,7 @@ my @children;
for my $i (1..$nproc) {
my ($r, $w);
pipe($r, $w) or BAIL_OUT $!;
- my $pid = fork;
+ my $pid = fork // BAIL_OUT "fork: $!";
if ($pid == 0) {
close $w;
while (my $i = <$r>) {
@@ -77,7 +77,6 @@ for my $i (1..$nproc) {
}
_exit(0);
}
- defined $pid or BAIL_OUT "fork: $!";
close $r or BAIL_OUT $!;
push @children, [ $w, $pid ];
$w->autoflush(1);