]> git.notmuchmail.org Git - notmuch/blobdiff - notmuch-reply.c
fix release date for 0.13.1
[notmuch] / notmuch-reply.c
index 0949d9fdc23eb5517695a10c352eabce9a66bf7b..7184a5dfcf887bb6fcb81bc8f1ee63171f7bb286 100644 (file)
@@ -740,9 +740,8 @@ notmuch_reply_command (void *ctx, int argc, char *argv[])
        return 1;
     }
 
-    notmuch = notmuch_database_open (notmuch_config_get_database_path (config),
-                                    NOTMUCH_DATABASE_MODE_READ_ONLY);
-    if (notmuch == NULL)
+    if (notmuch_database_open (notmuch_config_get_database_path (config),
+                              NOTMUCH_DATABASE_MODE_READ_ONLY, &notmuch))
        return 1;
 
     query = notmuch_query_create (notmuch, query_string);
@@ -755,7 +754,7 @@ notmuch_reply_command (void *ctx, int argc, char *argv[])
        return 1;
 
     notmuch_query_destroy (query);
-    notmuch_database_close (notmuch);
+    notmuch_database_destroy (notmuch);
 
     if (params.cryptoctx)
        g_object_unref(params.cryptoctx);