X-Git-Url: https://git.notmuchmail.org/git?p=notmuch;a=blobdiff_plain;f=notmuch-restore.c;h=4f4096ed15c79b11d06b97abfaa0be0b8fc2af5c;hp=02b563caae2dcbd5d52d223cf3ef6db4c2739d88;hb=5fddc07dc31481453c1af186bf7da241c00cdbf1;hpb=1579fb334e0bbc42d5ae7692b184127f43ed7027 diff --git a/notmuch-restore.c b/notmuch-restore.c index 02b563ca..4f4096ed 100644 --- a/notmuch-restore.c +++ b/notmuch-restore.c @@ -115,9 +115,8 @@ notmuch_restore_command (unused (void *ctx), int argc, char *argv[]) if (config == NULL) return 1; - notmuch = notmuch_database_open (notmuch_config_get_database_path (config), - NOTMUCH_DATABASE_MODE_READ_WRITE); - if (notmuch == NULL) + if (notmuch_database_open (notmuch_config_get_database_path (config), + NOTMUCH_DATABASE_MODE_READ_WRITE, ¬much)) return 1; synchronize_flags = notmuch_config_get_maildir_synchronize_flags (config);