gmime-cleanup: pass NULL as default GMimeParserOptions
authorDaniel Kahn Gillmor <dkg@fifthhorseman.net>
Thu, 2 May 2019 13:19:46 +0000 (09:19 -0400)
committerDavid Bremner <david@tethera.net>
Fri, 3 May 2019 09:58:00 +0000 (06:58 -0300)
This is a functional change, not a straight translation, because we
are no longer directly invoking g_mime_parser_options_get_default(),
but the GMime source has indicated that the options parameter for
g_mime_parser_construct_message() is "nullable" since upstream commit
d0ebdd2ea3e6fa635a2a551c846e9bc8b6040353 (which itself precedes GMime
3.0).

Signed-off-by: Daniel Kahn Gillmor <dkg@fifthhorseman.net>
lib/message-file.c
mime-node.c
util/gmime-extra.h

index c507ee340b5d0930617ff6f8ba5b2d4ad84ea93d..18802974fe87ed7ae26b18925dff015d5b5b110e 100644 (file)
@@ -152,7 +152,7 @@ _notmuch_message_file_parse (notmuch_message_file_t *message)
     parser = g_mime_parser_new_with_stream (stream);
     g_mime_parser_set_scan_from (parser, is_mbox);
 
-    message->message = g_mime_parser_construct_message (parser);
+    message->message = g_mime_parser_construct_message (parser, NULL);
     if (! message->message) {
        status = NOTMUCH_STATUS_FILE_NOT_EMAIL;
        goto DONE;
index 3fdf4808494f75af9f62fe0caa138faad4484dc4..cd3db67dfedde9d370f8cf7d78bf6a2bcef4698c 100644 (file)
@@ -121,7 +121,7 @@ mime_node_open (const void *ctx, notmuch_message_t *message,
        goto DONE;
     }
 
-    mctx->mime_message = g_mime_parser_construct_message (mctx->parser);
+    mctx->mime_message = g_mime_parser_construct_message (mctx->parser, NULL);
     if (!mctx->mime_message) {
        fprintf (stderr, "Failed to parse %s\n", filename);
        status = NOTMUCH_STATUS_FILE_ERROR;
index d2636b7854621d69c63c8127caffa05ca2e9a164..a42e43e72c01f16824c142b786875089f8630e6b 100644 (file)
@@ -9,8 +9,6 @@ extern "C" {
 
 GMimeStream *g_mime_stream_stdout_new(void);
 
-#define g_mime_parser_construct_message(p) g_mime_parser_construct_message (p, g_mime_parser_options_get_default ())
-
 /**
  * Get last 16 hex digits of fingerprint ("keyid")
  */