about summary refs log tree commit homepage
path: root/lib/PublicInbox/HTTPD/Async.pm
diff options
context:
space:
mode:
authorEric Wong <e@80x24.org>2016-07-09 04:51:37 +0000
committerEric Wong <e@80x24.org>2016-07-09 04:52:13 +0000
commit63d2e98ce28ddfefeac8bfdac409eae5efc03a9f (patch)
tree4dec15e825511818f21262f3174f0fcb6b0cae55 /lib/PublicInbox/HTTPD/Async.pm
parentacd3a41f52167b8e41cf34ab8164a9dfb5ef9c5c (diff)
downloadpublic-inbox-63d2e98ce28ddfefeac8bfdac409eae5efc03a9f.tar.gz
EvCleanup::asap events are not guaranteed to run after
Danga::Socket closes sockets at the event loop.  Thus we
must use slower Danga::Socket timers which are guaranteed
to run at the end of the event loop.
Diffstat (limited to 'lib/PublicInbox/HTTPD/Async.pm')
-rw-r--r--lib/PublicInbox/HTTPD/Async.pm2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/PublicInbox/HTTPD/Async.pm b/lib/PublicInbox/HTTPD/Async.pm
index 880cf021..68514f5a 100644
--- a/lib/PublicInbox/HTTPD/Async.pm
+++ b/lib/PublicInbox/HTTPD/Async.pm
@@ -72,7 +72,7 @@ sub close {
         $self->SUPER::close(@_);
 
         # we defer this to the next timer loop since close is deferred
-        PublicInbox::EvCleanup::asap($cleanup) if $cleanup;
+        PublicInbox::EvCleanup::next_tick($cleanup) if $cleanup;
 }
 
 1;