]> Sergey Matveev's repositories - public-inbox.git/blobdiff - lib/PublicInbox/ExtSearch.pm
gcf2 + extsearch: check for unlinked files on Linux
[public-inbox.git] / lib / PublicInbox / ExtSearch.pm
index bd301158a6b0a4163cb58073384bf034a5238dda..cd7cba2e88ce217bbc036a1655f479b291304efe 100644 (file)
@@ -33,12 +33,18 @@ sub misc {
 # same as per-inbox ->over, for now...
 sub over {
        my ($self) = @_;
-       $self->{over} //= PublicInbox::Over->new("$self->{xpfx}/over.sqlite3");
+       $self->{over} //= do {
+               PublicInbox::Inbox::_cleanup_later($self);
+               PublicInbox::Over->new("$self->{xpfx}/over.sqlite3");
+       };
 }
 
 sub git {
        my ($self) = @_;
-       $self->{git} //= PublicInbox::Git->new("$self->{topdir}/ALL.git");
+       $self->{git} //= do {
+               PublicInbox::Inbox::_cleanup_later($self);
+               PublicInbox::Git->new("$self->{topdir}/ALL.git");
+       };
 }
 
 # returns a hashref of { $NEWSGROUP_NAME => $ART_NO } using the `xref3' table