]> git.ipfire.org Git - thirdparty/public-inbox.git/commitdiff
cindex: keep batch pipe for pruning SHA-256 repos
authorEric Wong <e@80x24.org>
Thu, 30 Nov 2023 11:40:58 +0000 (11:40 +0000)
committerEric Wong <e@80x24.org>
Thu, 30 Nov 2023 21:36:52 +0000 (21:36 +0000)
This fixes the case where we're running both SHA-256 and SHA-1.
There's no tests for SHA-256, yet, but the bug is pretty obvious
upon reading the code.

lib/PublicInbox/CodeSearchIdx.pm

index cf6a6efe77ec3dd39a25cc8a5d4c64a74330b9f7..26018232f4cec1df6aaf2254148d3e5ff0ee671b 100644 (file)
@@ -1087,7 +1087,7 @@ sub run_prune { # OnDestroy when `git config extensions.objectFormat' are done
        # ) | awk | sort | comm | cidx_read_comm()
        my ($awk_opt, $sort_opt, $batch_opt);
        my $comm_opt = { -C => "$TMPDIR" };
-       pipe(local $awk_opt->{0}, local $batch_opt->{1});
+       pipe(local $awk_opt->{0}, $batch_opt->{1});
        pipe(local $sort_opt->{0}, local $awk_opt->{1});
        pipe(local $comm_opt->{0}, local $sort_opt->{1});
        run_await(\@AWK, $CMD_ENV, $awk_opt, \&cmd_done);