From: Thomas Roessler Date: Tue, 14 Nov 2000 16:56:42 +0000 (+0000) Subject: Try fixing a possible segmentation fault. I'm not entirely sure how X-Git-Tag: mutt-1-3-12-rel~13 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=92954afd792fd1124233dd1e44e88ad6aecae4db;p=mutt Try fixing a possible segmentation fault. I'm not entirely sure how I produced it, but it's at least obvious where it happened. --- diff --git a/curs_main.c b/curs_main.c index 902a663e..2bb2cd67 100644 --- a/curs_main.c +++ b/curs_main.c @@ -439,7 +439,7 @@ int mutt_index_menu (void) imap_allow_reopen (Context); #endif - index_hint = (Context->vcount && menu->current < Context->vcount) ? CURHDR->index : 0; + index_hint = (Context->vcount && menu->current >= 0 && menu->current < Context->vcount) ? CURHDR->index : 0; if ((check = mx_check_mailbox (Context, &index_hint, 0)) < 0) {