diff options
author | Matthew Barnes <mbarnes@redhat.com> | 2013-11-07 00:21:30 +0800 |
---|---|---|
committer | Matthew Barnes <mbarnes@redhat.com> | 2013-11-07 00:24:41 +0800 |
commit | 465050f57e0bd107a782a233e1f8733ea6edd671 (patch) | |
tree | f17fb71dcb0778bde1f099547d984e00713d7124 /em-format | |
parent | e260021d9472ee15739931ab8f7736c5ee2cfb12 (diff) | |
download | gsoc2013-evolution-465050f57e0bd107a782a233e1f8733ea6edd671.tar.gz gsoc2013-evolution-465050f57e0bd107a782a233e1f8733ea6edd671.tar.zst gsoc2013-evolution-465050f57e0bd107a782a233e1f8733ea6edd671.zip |
Bug 711532 - Infinite recursion from message/news attachment
This is only a partial solution for the test case the bug report.
The message/news part of the test case is also Base64-encoded, but
Evolution (or Camel) is not decoding it properly. Still digging.
Diffstat (limited to 'em-format')
-rw-r--r-- | em-format/e-mail-parser-message-rfc822.c | 5 | ||||
-rw-r--r-- | em-format/e-mail-parser-message.c | 2 |
2 files changed, 4 insertions, 3 deletions
diff --git a/em-format/e-mail-parser-message-rfc822.c b/em-format/e-mail-parser-message-rfc822.c index e9bfab15a3..3d0078cd81 100644 --- a/em-format/e-mail-parser-message-rfc822.c +++ b/em-format/e-mail-parser-message-rfc822.c @@ -73,7 +73,7 @@ empe_msg_rfc822_parse (EMailParserExtension *extension, * CamelMimePart, sometimes the CamelMimePart itself represents * the RFC822 message. */ ct = camel_mime_part_get_content_type (part); - if (camel_content_type_is (ct, "message", "rfc822")) { + if (camel_content_type_is (ct, "message", "*")) { new_stream = camel_stream_mem_new (); mime_parser = camel_mime_parser_new (); message = (CamelMimePart *) camel_mime_message_new (); @@ -82,7 +82,8 @@ empe_msg_rfc822_parse (EMailParserExtension *extension, camel_data_wrapper_decode_to_stream_sync ( dw, new_stream, cancellable, NULL); g_seekable_seek ( - G_SEEKABLE (new_stream), 0, G_SEEK_SET, cancellable, NULL); + G_SEEKABLE (new_stream), 0, + G_SEEK_SET, cancellable, NULL); camel_mime_parser_init_with_stream ( mime_parser, new_stream, NULL); camel_mime_part_construct_from_parser_sync ( diff --git a/em-format/e-mail-parser-message.c b/em-format/e-mail-parser-message.c index 609663201c..706518001c 100644 --- a/em-format/e-mail-parser-message.c +++ b/em-format/e-mail-parser-message.c @@ -72,7 +72,7 @@ empe_message_parse (EMailParserExtension *extension, ct = camel_mime_part_get_content_type (part); mime_type = camel_content_type_simple (ct); - if (mime_type && g_ascii_strcasecmp (mime_type, "message/rfc822") == 0) { + if (camel_content_type_is (ct, "message", "*")) { /* get mime type of the content of the message, * instead of using a generic message/rfc822 */ CamelDataWrapper *content; |