]> granicus.if.org Git - neomutt/commitdiff
quasi-delete: check there's a selection
authorRichard Russon <rich@flatcap.org>
Fri, 16 Sep 2016 18:51:47 +0000 (19:51 +0100)
committerRichard Russon <rich@flatcap.org>
Tue, 27 Sep 2016 23:01:41 +0000 (00:01 +0100)
If you created a vfolder with no contents, then tried to quasi-delete
something, it would crash.

curs_main.c

index f71e4e5fbbf950ab1394e935734b6fb88f390ba5..f04fd9d2b4c24db139a84cb90a9e282fb101aec6 100644 (file)
@@ -1623,6 +1623,8 @@ int mutt_index_menu (void)
        break;
 
       case OP_MAIN_QUASI_DELETE:
+       CHECK_MSGCOUNT;
+        CHECK_VISIBLE;
        if (tag) {
          for (j = 0; j < Context->vcount; j++) {
            if (Context->hdrs[Context->v2r[j]]->tagged) {