From: Thomas Roessler Date: Tue, 13 Feb 2001 10:54:29 +0000 (+0000) Subject: Fix #470: multipart- and message-type attachments weren't handled X-Git-Tag: mutt-1-3-16-rel~34 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=715dc97d9404e851912c0e0e80dab91029cfd0de;p=mutt Fix #470: multipart- and message-type attachments weren't handled correctly. --- diff --git a/attach.c b/attach.c index 1a76cf00..19503d24 100644 --- a/attach.c +++ b/attach.c @@ -818,15 +818,16 @@ int mutt_decode_save_attachment (FILE *fp, BODY *m, char *path, } saved_encoding = m->encoding; + if (!is_multipart (m)) + m->encoding = ENC8BIT; + m->length = st.st_size; - m->encoding = ENC8BIT; m->offset = 0; saved_parts = m->parts; saved_hdr = m->hdr; mutt_parse_part (s.fpin, m); - /* display a readable version to the user */ - if (m->noconv) + if (m->noconv || is_multipart (m)) s.flags |= M_CHARCONV; } else