[evolution] Don't re-parse attachment parts as attachments



commit f836b409df8873b773907f8d3c1a1537008e5f9a
Author: Dan VrÃtil <dvratil redhat com>
Date:   Tue Sep 11 13:47:17 2012 +0200

    Don't re-parse attachment parts as attachments

 em-format/e-mail-parser-multipart-mixed.c |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)
---
diff --git a/em-format/e-mail-parser-multipart-mixed.c b/em-format/e-mail-parser-multipart-mixed.c
index e00174c..c8e2995 100644
--- a/em-format/e-mail-parser-multipart-mixed.c
+++ b/em-format/e-mail-parser-multipart-mixed.c
@@ -99,9 +99,11 @@ empe_mp_mixed_parse (EMailParserExtension *extension,
 
 		ct = camel_mime_part_get_content_type (subpart);
 
-		/* Display parts with CID as attachments */
+		/* Display parts with CID as attachments (unless they already are
+		 * attachments) */
 		if (new_parts && new_parts->data &&
-			(E_MAIL_PART (new_parts->data)->cid != NULL)) {
+			(E_MAIL_PART (new_parts->data)->cid != NULL) &&
+			!E_MAIL_PART (new_parts->data)->is_attachment) {
 
 			parts = g_slist_concat (parts,
 					e_mail_parser_wrap_as_attachment (



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]