about summary refs log tree commit homepage
path: root/lib/PublicInbox/GzipFilter.pm
diff options
context:
space:
mode:
authorEric Wong <e@80x24.org>2021-09-28 23:11:04 +0000
committerEric Wong <e@80x24.org>2021-09-29 00:08:32 +0000
commita29d72521f20576916e4c407263566cfa972416b (patch)
treea5bb5d273007df9d490433fa5ef33b802695b037 /lib/PublicInbox/GzipFilter.pm
parent205599c0814e1031760e54cce9d8880e747cbb08 (diff)
downloadpublic-inbox-a29d72521f20576916e4c407263566cfa972416b.tar.gz
SQLite files may be replaced or removed by admins while
generating a large threads or mailbox responses.  Ensure we
don't hold onto DBI handles and associated file descriptors
past their cleanup.
Diffstat (limited to 'lib/PublicInbox/GzipFilter.pm')
-rw-r--r--lib/PublicInbox/GzipFilter.pm6
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/PublicInbox/GzipFilter.pm b/lib/PublicInbox/GzipFilter.pm
index c50c26c5..624c2ed3 100644
--- a/lib/PublicInbox/GzipFilter.pm
+++ b/lib/PublicInbox/GzipFilter.pm
@@ -84,6 +84,12 @@ sub gzip_or_die () {
         $gz;
 }
 
+sub gone { # what: search/over/mm
+        my ($ctx, $what) = @_;
+        warn "W: `$ctx->{ibx}->{name}' $what went away unexpectedly\n";
+        undef;
+}
+
 # for GetlineBody (via Qspawn) when NOT using $env->{'pi-httpd.async'}
 # Also used for ->getline callbacks
 sub translate ($$) {