]> git.notmuchmail.org Git - notmuch/blobdiff - database.cc
Fix segfault in case of the database lock not being available.
[notmuch] / database.cc
index 0fd0bdadf8103366b4c2f95924926d1f532df0ca..71246eb456115ade91ee9b47b89629850ab32e11 100644 (file)
@@ -104,12 +104,12 @@ typedef struct {
 
 prefix_t BOOLEAN_PREFIX_INTERNAL[] = {
     { "type", "T" },
-    { "thread", "G" },
     { "ref", "XREFERENCE" },
     { "timestamp", "XTIMESTAMP" },
 };
 
 prefix_t BOOLEAN_PREFIX_EXTERNAL[] = {
+    { "thread", "G" },
     { "tag", "K" },
     { "id", "Q" }
 };
@@ -489,6 +489,7 @@ notmuch_database_open (const char *path)
     } catch (const Xapian::Error &error) {
        fprintf (stderr, "A Xapian exception occurred: %s\n",
                 error.get_msg().c_str());
+       notmuch = NULL;
     }
     
   DONE: