diff options
author | Milan Crha <mcrha@redhat.com> | 2012-09-12 17:39:14 +0800 |
---|---|---|
committer | Milan Crha <mcrha@redhat.com> | 2012-09-12 17:39:14 +0800 |
commit | 251e8b00da7f55c076c67d7a100fd4d7b3375051 (patch) | |
tree | 8db4fa00bc925b997ff786da759f6d59211871ce | |
parent | 17ecde5404d585f973d8a0c895c5cf5c6274fd30 (diff) | |
download | gsoc2013-evolution-251e8b00da7f55c076c67d7a100fd4d7b3375051.tar.gz gsoc2013-evolution-251e8b00da7f55c076c67d7a100fd4d7b3375051.tar.zst gsoc2013-evolution-251e8b00da7f55c076c67d7a100fd4d7b3375051.zip |
Bug #678291 - Identifies application/mbox as text/plain attachment
-rw-r--r-- | em-format/e-mail-parser-application-mbox.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/em-format/e-mail-parser-application-mbox.c b/em-format/e-mail-parser-application-mbox.c index 500b6bbc1e..d8224e35c1 100644 --- a/em-format/e-mail-parser-application-mbox.c +++ b/em-format/e-mail-parser-application-mbox.c @@ -140,13 +140,17 @@ empe_app_mbox_parse (EMailParserExtension *extension, g_string_append_printf (part_id, ".mbox.%d", messages); + opart = camel_mime_part_new (); + camel_medium_set_content (CAMEL_MEDIUM (opart), CAMEL_DATA_WRAPPER (message)); + camel_data_wrapper_set_mime_type (CAMEL_DATA_WRAPPER (opart), "message/rfc822"); + new_parts = e_mail_parser_parse_part_as ( - parser, CAMEL_MIME_PART (message), + parser, opart, part_id, "message/rfc822", cancellable); /* Wrap every message as attachment */ new_parts = e_mail_parser_wrap_as_attachment ( - parser, CAMEL_MIME_PART (message), + parser, opart, new_parts, part_id, cancellable); /* Inline all messages in mbox */ @@ -161,6 +165,7 @@ empe_app_mbox_parse (EMailParserExtension *extension, g_string_truncate (part_id, old_len); g_object_unref (message); + g_object_unref (opart); /* Skip past CAMEL_MIME_PARSER_STATE_FROM_END. */ camel_mime_parser_step (mime_parser, NULL, NULL); |