From: Kevin McCarthy Date: Fri, 1 Jul 2016 20:33:20 +0000 (-0700) Subject: Check $pgp_autoinline and $pgp_replyinline if oppenc is set. (closes #3846) X-Git-Tag: neomutt-20160822~93^2 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=c47e40344f5d2d2314928a4eb13bd7d77a18fb06;p=neomutt Check $pgp_autoinline and $pgp_replyinline if oppenc is set. (closes #3846) The first oppenc call takes place after the initial checks of $pgp_autoline and $pgp_replyinline, and doesn't go through the pgp menu. Therefore, check for $pgp_autoline and $pgp_replyinline if oppenc is set too, to avoid oppenc enabling encryption without INLINE being set in those cases. a6a4d6ed0f19 previously cleaned things up so that it is safe to set INLINE even if encryption isn't enabled. --- diff --git a/send.c b/send.c index 387de5dbf..8b71ea574 100644 --- a/send.c +++ b/send.c @@ -1507,7 +1507,8 @@ ci_send_message (int flags, /* send mode */ msg->security |= SIGN; if (option (OPTCRYPTREPLYSIGNENCRYPTED) && cur && (cur->security & ENCRYPT)) msg->security |= SIGN; - if (WithCrypto & APPLICATION_PGP && (msg->security & (ENCRYPT | SIGN))) + if ((WithCrypto & APPLICATION_PGP) && + ((msg->security & (ENCRYPT | SIGN)) || option (OPTCRYPTOPPORTUNISTICENCRYPT))) { if (option (OPTPGPAUTOINLINE)) msg->security |= INLINE;