about summary refs log tree commit homepage
path: root/lib/PublicInbox
diff options
context:
space:
mode:
authorEric Wong <e@80x24.org>2019-10-21 19:19:00 +0000
committerEric Wong <e@80x24.org>2019-10-22 01:25:33 +0000
commit96a8b8832d791d53e05f235b5bc2492daab5f60a (patch)
tree88bdf2227fb573d657809d1b1e4ac0c7e6b06f55 /lib/PublicInbox
parent8742421ba3503e1865b9f1a2561318e3a58c4b3c (diff)
downloadpublic-inbox-96a8b8832d791d53e05f235b5bc2492daab5f60a.tar.gz
v2writable: move git->cleanup to the correct place
We need to stop the git process to avoid leaking FDs
to Xapian if we recurse ->index_sync on reindex.
Diffstat (limited to 'lib/PublicInbox')
-rw-r--r--lib/PublicInbox/V2Writable.pm2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/PublicInbox/V2Writable.pm b/lib/PublicInbox/V2Writable.pm
index 7ece6b01..33c0038d 100644
--- a/lib/PublicInbox/V2Writable.pm
+++ b/lib/PublicInbox/V2Writable.pm
@@ -1280,8 +1280,8 @@ sub index_sync {
                         $self->{current_info} = "multi_mid $oid";
                         reindex_oid_m($self, $sync, $git, $oid);
                 }
-                $git->cleanup if $git;
         }
+        $git->cleanup if $git;
         $self->done;
 
         if (my $nr = $sync->{nr}) {