X-Git-Url: http://www.git.stargrave.org/?a=blobdiff_plain;f=lib%2FPublicInbox%2FIMAP.pm;h=d4ef6efe156d2b3efde19d4eafa08aa3a760b73d;hb=01f2e00be4671e1100b6180310c0fd8c0035ebc8;hp=9ae7c60e75ee161eb276b23d750fa65c4ea9a7ce;hpb=97cb0db690cc2065e7e3c33ea5f3636dc0b538c5;p=public-inbox.git diff --git a/lib/PublicInbox/IMAP.pm b/lib/PublicInbox/IMAP.pm index 9ae7c60e..d4ef6efe 100644 --- a/lib/PublicInbox/IMAP.pm +++ b/lib/PublicInbox/IMAP.pm @@ -1462,6 +1462,10 @@ sub cmd_starttls ($$) { # for graceful shutdown in PublicInbox::Daemon: sub busy { my ($self, $now) = @_; + if (defined($self->{-idle_tag})) { + $self->write(\"* BYE server shutting down\r\n"); + return; # not busy anymore + } ($self->{rbuf} || $self->{wbuf} || $self->not_idle_long($now)); }