[balsa] Assert that a mailbox is either IMAP or local



commit d29194623fed320f173caa2f65b44899c92415b9
Author: Peter Bloomfield <PeterBloomfield bellsouth net>
Date:   Mon Jun 26 18:06:39 2017 -0400

    Assert that a mailbox is either IMAP or local
    
        * src/main-window.c (bw_mailbox_check): assert that a mailbox is
        either IMAP or local.

 src/main-window.c |    6 +++++-
 1 files changed, 5 insertions(+), 1 deletions(-)
---
diff --git a/src/main-window.c b/src/main-window.c
index b31c68a..118cba1 100644
--- a/src/main-window.c
+++ b/src/main-window.c
@@ -3426,8 +3426,12 @@ bw_mailbox_check(LibBalsaMailbox * mailbox, BalsaWindow * window)
        string = g_strdup_printf(_("IMAP mailbox: %s"), mailbox->url);
         if (balsa_app.debug)
             fprintf(stderr, "%s\n", string);
-    } else if (LIBBALSA_IS_MAILBOX_LOCAL(mailbox))
+    } else if (LIBBALSA_IS_MAILBOX_LOCAL(mailbox)) {
        string = g_strdup_printf(_("Local mailbox: %s"), mailbox->name);
+    } else {
+        g_assert_not_reached();
+    }
+
     MSGMAILTHREAD(threadmessage, LIBBALSA_NTFY_SOURCE, NULL, string, 0, 0);
     g_free(string);
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]