]> granicus.if.org Git - neomutt/commitdiff
dead code - do_database_open
authorRichard Russon <rich@flatcap.org>
Mon, 19 Mar 2018 10:19:11 +0000 (10:19 +0000)
committerRichard Russon <rich@flatcap.org>
Tue, 20 Mar 2018 01:01:44 +0000 (01:01 +0000)
mutt_notmuch.c

index 52877944315ef85a8fe3f90ed1bc49c0e8a05035..5ac108c0f5d67556a395439d37aff3dffceb27e6 100644 (file)
@@ -482,7 +482,9 @@ static notmuch_database_t *do_database_open(const char *filename, bool writable,
   notmuch_database_t *db = NULL;
   int ct = 0;
   notmuch_status_t st = NOTMUCH_STATUS_SUCCESS;
+#if LIBNOTMUCH_CHECK_VERSION(4, 2, 0)
   char *msg = NULL;
+#endif
 
   mutt_debug(1, "nm: db open '%s' %s (timeout %d)\n", filename,
              writable ? "[WRITE]" : "[READ]", NmOpenTimeout);
@@ -513,12 +515,14 @@ static notmuch_database_t *do_database_open(const char *filename, bool writable,
   {
     if (!db)
     {
+#if LIBNOTMUCH_CHECK_VERSION(4, 2, 0)
       if (msg)
       {
         mutt_error(msg);
         FREE(&msg);
       }
       else
+#endif
       {
         mutt_error(_("Cannot open notmuch database: %s: %s"), filename,
                    st ? notmuch_status_to_string(st) : _("unknown reason"));