summaryrefslogtreecommitdiffstats
path: root/sendlib.c
diff options
context:
space:
mode:
authorThomas Roessler <roessler@does-not-exist.org>1998-09-07 20:40:51 +0000
committerThomas Roessler <roessler@does-not-exist.org>1998-09-07 20:40:51 +0000
commit18ae85862e640bf145ae27cb20c6e874c9bd8c6d (patch)
tree42eafe6aa5b2d7d6601c7867e294770f5e74e487 /sendlib.c
parent09d790e66ba68a1cd4e2dd3b775ac319180bbbfd (diff)
[patch-0.94.5i.tlr.pgp_fixes.1] This patch fixes various
pgp-related issues. In particular, mutt won't segfault when trying to decrypt-save messages from the index, and the presence of a PGP-encrypted body part on the attachment menu will no longer confuse the MIME parser.
Diffstat (limited to 'sendlib.c')
-rw-r--r--sendlib.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/sendlib.c b/sendlib.c
index 883eb918..6ff67552 100644
--- a/sendlib.c
+++ b/sendlib.c
@@ -954,14 +954,13 @@ BODY *mutt_make_message_attach (CONTEXT *ctx, HEADER *hdr, int attach_msg)
if(option(OPTFORWDECRYPT)
&& (hdr->pgp & PGPENCRYPT))
{
- if(hdr->content->type == TYPEMULTIPART)
+ if(mutt_is_multipart_encrypted(hdr->content))
{
chflags |= CH_MIME | CH_NONEWLINE;
cmflags = M_CM_DECODE_PGP;
pgp &= ~PGPENCRYPT;
}
- else if((hdr->content->type == TYPEAPPLICATION) &&
- mutt_is_pgp_subtype(hdr->content->subtype))
+ else if(mutt_is_application_pgp(hdr->content) & PGPENCRYPT)
{
chflags |= CH_MIME | CH_TXTPLAIN;
cmflags = M_CM_DECODE;