- pos += strlen (strncat (buffylist, _("New mail in "), sizeof (buffylist) - 1 - pos)); /* __STRNCAT_CHECKED__ */
- for (tmp = Incoming; tmp; tmp = tmp->next) {
- /* Is there new mail in this mailbox? */
- if (tmp->new <= 0 || (have_unnotified && tmp->notified))
- continue;
-
- strfcpy (path, tmp->path, sizeof (path));
- mutt_pretty_mailbox (path);
-
- if (!first && pos + strlen (path) >= COLS - 7)
- break;
+ pos += str_len (strncat (buffylist, _("New mail in "), sizeof (buffylist) - 1 - pos)); /* __STRNCAT_CHECKED__ */
+ if (Incoming) {
+ for (i = 0; i < Incoming->length; i++) {
+ tmp = (BUFFY*) Incoming->data[i];
+ /* Is there new mail in this mailbox? */
+ if (tmp->new <= 0 || (have_unnotified && tmp->notified))
+ continue;
+
+ strfcpy (path, tmp->path, sizeof (path));
+ mutt_pretty_mailbox (path);
+
+ if (!first && pos + str_len (path) >= COLS - 7)
+ break;