From: Andreas Jaggi Date: Sun, 9 Sep 2007 22:48:23 +0000 (-0700) Subject: Let imap_complete_hosts work with the last mailbox (closes #2949). X-Git-Tag: mutt-1-5-17-rel~45 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=6ae2bbb54f44e21ae98fb2158dd6427374c5ce8a;p=mutt Let imap_complete_hosts work with the last mailbox (closes #2949). This was an off-by-one error in the mailbox loop. --- diff --git a/imap/imap.c b/imap/imap.c index 2eb8181d..bc1ca394 100644 --- a/imap/imap.c +++ b/imap/imap.c @@ -1866,7 +1866,7 @@ imap_complete_hosts (char *dest, size_t len) int matchlen; matchlen = mutt_strlen (dest); - for (mailbox = Incoming; mailbox && mailbox->next; mailbox = mailbox->next) + for (mailbox = Incoming; mailbox; mailbox = mailbox->next) { if (!mutt_strncmp (dest, mailbox->path, matchlen)) {