diff options
| author | David Bremner <david@tethera.net> | 2021-02-14 13:54:37 -0400 |
|---|---|---|
| committer | David Bremner <david@tethera.net> | 2021-03-27 09:26:14 -0300 |
| commit | 79a4b2e9e749b46433be64c7c9cc56d3cb43262e (patch) | |
| tree | dc67cde865978aecf9f1ae9cc4ad24cca7ec57b1 | |
| parent | a6a580e61613507edc47e0eac0b2b84f6678d01c (diff) | |
test: convert random-corpus to use n_d_open_with_config
Remove one more usage of notmuch_config_get_database_path
| -rw-r--r-- | test/random-corpus.c | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/test/random-corpus.c b/test/random-corpus.c index d0354e35..7cde22c5 100644 --- a/test/random-corpus.c +++ b/test/random-corpus.c @@ -141,7 +141,6 @@ main (int argc, char **argv) void *ctx = talloc_new (NULL); const char *config_path = NULL; - notmuch_config_t *config; notmuch_database_t *notmuch; int num_messages = 500; @@ -179,12 +178,12 @@ main (int argc, char **argv) exit (1); } - config = notmuch_config_open (ctx, config_path, false); - if (config == NULL) - return 1; - - if (notmuch_database_open (notmuch_config_get_database_path (config), - NOTMUCH_DATABASE_MODE_READ_WRITE, ¬much)) + if (notmuch_database_open_with_config (NULL, + NOTMUCH_DATABASE_MODE_READ_WRITE, + config_path, + NULL, + ¬much, + NULL)) return 1; srandom (seed); |
