From: Eric Wong (Contractor, The Linux Foundation) Date: Mon, 10 Jun 2019 21:43:52 +0000 (+0000) Subject: v2writable: replace: kill git processes before reindexing X-Git-Tag: v1.2.0~179^2~1 X-Git-Url: http://www.git.stargrave.org/?a=commitdiff_plain;h=8388a137ac3b13edaa361a7fb6c85fea3c409ea8;p=public-inbox.git v2writable: replace: kill git processes before reindexing Xapian on Linux <3.15 has trouble with coprocesses since it used fork() for locking and would hold onto pipes used for git unnecessarily. --- diff --git a/lib/PublicInbox/V2Writable.pm b/lib/PublicInbox/V2Writable.pm index 3484807b..09ed4e7b 100644 --- a/lib/PublicInbox/V2Writable.pm +++ b/lib/PublicInbox/V2Writable.pm @@ -533,6 +533,9 @@ W: $list my ($oid, $type, $len) = $self->{-inbox}->git->check($expect_oid); $oid eq $expect_oid or die "BUG: $expect_oid not found after replace"; + # don't leak FDs to Xapian: + $self->{-inbox}->git->cleanup; + # reindex modified messages: for my $smsg (@$need_reindex) { my $num = $smsg->{num};