]> Sergey Matveev's repositories - public-inbox.git/commitdiff
index: avoid setting NPROC to undef
authorEric Wong <e@80x24.org>
Wed, 16 May 2018 05:33:26 +0000 (05:33 +0000)
committerEric Wong <e@80x24.org>
Thu, 17 May 2018 02:52:34 +0000 (02:52 +0000)
This quiets a warning inside Spawn.pm

script/public-inbox-index

index db7ebbab6421ec2cc1b849e4259b2ac82d6d745b..2a7a524b34abee1765c3adc9288b64cf29dac78e 100755 (executable)
@@ -101,7 +101,7 @@ sub index_dir {
                eval { require PublicInbox::V2Writable };
                die "v2 requirements not met: $@\n" if $@;
                my $v2w = eval {
-                       local $ENV{NPROC} = $jobs if $jobs;
+                       $jobs and local $ENV{NPROC} = $jobs;
                        PublicInbox::V2Writable->new($repo);
                };
                if (defined $jobs) {