From 42a6fc1794099cb2585d3c290e42a20d5ef56b89 Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Tue, 7 Jul 2020 20:37:37 +0000 Subject: imap: avoid warnings on non-slice mailboxes Non-slice mailboxes never have messages themselves, so we must not assume a message exists when sending untagged EXISTS messages. --- lib/PublicInbox/IMAP.pm | 1 + 1 file changed, 1 insertion(+) (limited to 'lib/PublicInbox/IMAP.pm') diff --git a/lib/PublicInbox/IMAP.pm b/lib/PublicInbox/IMAP.pm index d8c898f4..8ab4b1e7 100644 --- a/lib/PublicInbox/IMAP.pm +++ b/lib/PublicInbox/IMAP.pm @@ -246,6 +246,7 @@ sub uo2m_extend ($$;$) { my $base = $self->{uid_base}; ++$beg; my $uids = $self->{ibx}->over->uid_range($beg, $base + UID_SLICE); + return $uo2m if !scalar(@$uids); my @tmp; # [$UID_OFFSET] => $MSN my $write_method = $_[2] // 'msg_more'; if (ref($uo2m)) { -- cgit v1.2.3-24-ge0c7