about summary refs log tree commit homepage
path: root/lib/PublicInbox/Inbox.pm
diff options
context:
space:
mode:
authorEric Wong (Contractor, The Linux Foundation) <e@80x24.org>2018-03-02 03:12:23 +0000
committerEric Wong (Contractor, The Linux Foundation) <e@80x24.org>2018-03-02 09:06:08 +0000
commitc062644c64bf44b48bd6469e1d4e77d8b9cfdc87 (patch)
tree68d4fd7e3578419bd5d3ccb20b9aae0bc5d92ad2 /lib/PublicInbox/Inbox.pm
parent6d448aae2a6624d37b291946b6666d5101c2957b (diff)
downloadpublic-inbox-c062644c64bf44b48bd6469e1d4e77d8b9cfdc87.tar.gz
We'll be using these in a more OO manner for V2Writable
(which doesn't use Danga::Socket), so lets not unnecessarily
register cleanup handlers intended for network daemons.
Diffstat (limited to 'lib/PublicInbox/Inbox.pm')
-rw-r--r--lib/PublicInbox/Inbox.pm1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/PublicInbox/Inbox.pm b/lib/PublicInbox/Inbox.pm
index 54a6eb32..b9cd4c40 100644
--- a/lib/PublicInbox/Inbox.pm
+++ b/lib/PublicInbox/Inbox.pm
@@ -29,6 +29,7 @@ sub cleanup_task () {
 
 sub _cleanup_later ($) {
         my ($self) = @_;
+        return unless $PublicInbox::EvCleanup::ENABLED;
         $cleanup_timer ||= PublicInbox::EvCleanup::later(*cleanup_task);
         $CLEANUP->{"$self"} = $self;
 }