From ab431a4a6919f6e75e2033db7f3309a7b9f88507 Mon Sep 17 00:00:00 2001 From: djcb Date: Thu, 27 Sep 2012 17:31:49 +0300 Subject: [PATCH] * lib: don't be too picky considering what's an attachment --- lib/mu-msg-part.c | 11 +++++------ mu/mu-cmd-extract.c | 2 -- 2 files changed, 5 insertions(+), 8 deletions(-) diff --git a/lib/mu-msg-part.c b/lib/mu-msg-part.c index e532538c..2f86b875 100644 --- a/lib/mu-msg-part.c +++ b/lib/mu-msg-part.c @@ -881,12 +881,11 @@ mu_msg_part_maybe_attachment (MuMsgPart *part) if (!(part->part_type & MU_MSG_PART_TYPE_LEAF)) return FALSE; - /* non-textual parts are considered attachments as - * well */ - /* if (!(part->part_type & MU_MSG_PART_TYPE_ATTACHMENT) && */ - /* !(part->part_type & MU_MSG_PART_TYPE_TEXT_PLAIN) && */ - /* !(part->part_type & MU_MSG_PART_TYPE_TEXT_HTML)) */ - /* return TRUE; */ + /* parts other than text/plain, text/html are considered + * attachments as well */ + if (!(part->part_type & MU_MSG_PART_TYPE_TEXT_PLAIN) && + !(part->part_type & MU_MSG_PART_TYPE_TEXT_HTML)) + return TRUE; return part->part_type & MU_MSG_PART_TYPE_ATTACHMENT ? TRUE : FALSE; } diff --git a/mu/mu-cmd-extract.c b/mu/mu-cmd-extract.c index 7369f76d..76cead5d 100644 --- a/mu/mu-cmd-extract.c +++ b/mu/mu-cmd-extract.c @@ -162,8 +162,6 @@ save_part_with_filename (MuMsg *msg, const char *pattern, MuConfig *opts) return rv; } - - struct _SaveData { gboolean result; guint saved_num;