On Thu, 8 Mar 2012 11:35:35 -0400, David Bremner <[email protected]> wrote:
> I ran out of time for the moment, but the following patch gets me down from > 4196 failures on the notmuch mailing list to 3422. That patch is of course complete nonsense. Attached is another silly patch, which at least demonstrates the problem. With the attached patch, notmuch (+ gmime-2.6) only fails for non-mbox messages. So I guess we need a way to detect if a file is mbox before parsing? or a way to get gmime to be less strict here?
>From 7fb942049ae68e09ebb9fbca40048f95543ab4b8 Mon Sep 17 00:00:00 2001 From: David Bremner <[email protected]> Date: Thu, 8 Mar 2012 11:11:21 -0400 Subject: [PATCH] WIP debugging gmime-2.6 problems Unconditionally tell gmime to look for an mbox. This of course makes it fail for non-mboxes. --- mime-node.c | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) diff --git a/mime-node.c b/mime-node.c index a95bdab..3e07fbf 100644 --- a/mime-node.c +++ b/mime-node.c @@ -111,7 +111,9 @@ mime_node_open (const void *ctx, notmuch_message_t *message, goto DONE; } + g_mime_parser_set_scan_from(mctx->parser, TRUE); mctx->mime_message = g_mime_parser_construct_message (mctx->parser); + if (!mctx->mime_message) { fprintf (stderr, "Failed to parse %s\n", filename); status = NOTMUCH_STATUS_FILE_ERROR; -- 1.7.9.1
_______________________________________________ notmuch mailing list [email protected] http://notmuchmail.org/mailman/listinfo/notmuch
