aboutsummaryrefslogtreecommitdiff
path: root/notmuch-dump.c
diff options
context:
space:
mode:
authorDavid Bremner <david@tethera.net>2020-04-12 20:00:31 -0300
committerDavid Bremner <david@tethera.net>2020-04-13 17:13:55 -0300
commit2c1f783f5f4ad28d89f2e83d7253bae7bba98440 (patch)
tree625c4cec17dbfe044c0bc78c8c96adf6221d63bb /notmuch-dump.c
parentd50f41c0fd0bbd2ca2b364f49deaea8be63dff3c (diff)
don't pass NULL as second parameter to gzerror
Although (as of 1.2.11) zlib checks this parameter before writing to it, the docs don't promise to keep doing so, so be safe.
Diffstat (limited to 'notmuch-dump.c')
-rw-r--r--notmuch-dump.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/notmuch-dump.c b/notmuch-dump.c
index 65e02639..af346ba2 100644
--- a/notmuch-dump.c
+++ b/notmuch-dump.c
@@ -21,7 +21,7 @@
#include "notmuch-client.h"
#include "hex-escape.h"
#include "string-util.h"
-#include <zlib.h>
+#include "zlib-extra.h"
static int
database_dump_config (notmuch_database_t *notmuch, gzFile output)
@@ -316,7 +316,7 @@ notmuch_database_dump (notmuch_database_t *notmuch,
ret = gzflush (output, Z_FINISH);
if (ret) {
- fprintf (stderr, "Error flushing output: %s\n", gzerror (output, NULL));
+ fprintf (stderr, "Error flushing output: %s\n", gzerror_str (output));
goto DONE;
}
@@ -332,7 +332,7 @@ notmuch_database_dump (notmuch_database_t *notmuch,
ret = gzclose_w (output);
if (ret) {
fprintf (stderr, "Error closing %s: %s\n", name_for_error,
- gzerror (output, NULL));
+ gzerror_str (output));
ret = EXIT_FAILURE;
output = NULL;
goto DONE;