]> granicus.if.org Git - mutt/commitdiff
Have $forward_attachments look at attachment disposition.
authorKevin McCarthy <kevin@8t8.us>
Sat, 25 May 2019 20:12:04 +0000 (13:12 -0700)
committerKevin McCarthy <kevin@8t8.us>
Sat, 25 May 2019 20:12:04 +0000 (13:12 -0700)
If $honor_disposition is set, an "attachment" disposition decodable
attachment won't be included in the body, so we want it to be added as
an attachment to the forwarded email.

send.c

diff --git a/send.c b/send.c
index 7c1460c3336bcc080b54360a08b60526bdf51a9a..e1c9d2f49d37ad42b815e42f438d32d85649d2d8 100644 (file)
--- a/send.c
+++ b/send.c
@@ -419,7 +419,8 @@ static int inline_forward_attachments (CONTEXT *ctx, HEADER *cur,
   {
     body = actx->idx[i]->content;
     if ((body->type != TYPEMULTIPART) &&
-       !mutt_can_decode (body) &&
+       (!mutt_can_decode (body) ||
+         (option (OPTHONORDISP) && body->disposition == DISPATTACH)) &&
         !(body->type == TYPEAPPLICATION &&
           (!ascii_strcasecmp (body->subtype, "pgp-signature") ||
            !ascii_strcasecmp (body->subtype, "x-pkcs7-signature") ||