my ($y) = ($b =~ m!/([0-9]+)/*\z!);
($y // -1) <=> ($x // -1) # we may have non-shards
} keys %$tmp;
-
- my ($dname) = ($order[0] =~ m!(.*/)[^/]+/*\z!);
- my $mode = (stat($dname))[2];
+ my ($xpfx, $mode);
+ if (@order) {
+ ($xpfx) = ($order[0] =~ m!(.*/)[^/]+/*\z!);
+ $mode = (stat($xpfx))[2];
+ }
for my $old (@order) {
next if $old eq ''; # no invalid paths
my $newdir = $tmp->{$old};
$ibx->{inboxdir}, "-L$level");
push @cmd, '-c' if have_xapian_compact;
ok(run_script(\@cmd, undef, { 2 => \$err }), 'index master');
+ unlike $err, qr/Use of uninitialized/, 'no uninitialized warnings';
my $ro_master = PublicInbox::Inbox->new({
inboxdir => $ibx->{inboxdir},
indexlevel => $level
my $cmd = [ qw(-compact), $mirror ];
ok(run_script($cmd, undef, { 2 => \$err}), "compact $level")
or diag $err;
+ unlike $err, qr/Use of uninitialized/,
+ 'no uninitialized warnings';
}
};