Re: problem w/ pgp_autoinline?
On Wed, Feb 02, 2005 at 08:29:26PM +0100, Adeodato wrote:
> FWIW, I have in my postponed folder a mail that reads:
>
> Subject: [PATCH] pgp_autoinline is not honoured when manually signing a
> mail
>
> It is back from August, the body is empty and there is no patch
> anywhere, so badluck.
So sad. You probably had something like this (untested patch attached).
--
tamo
# I temporarily unset $honour_followup_to
# because several messages have been ignored by the listserver.
--- pgp.c.BAK Mon Jan 31 22:51:01 2005
+++ pgp.c Thu Feb 3 17:59:42 2005
@@ -1475,6 +1475,7 @@
int pgp_send_menu (HEADER *msg, int *redraw)
{
+ int prefer_inline;
pgp_key_t p;
char input_signas[SHORT_STRING];
@@ -1482,6 +1483,13 @@
if (!(WithCrypto & APPLICATION_PGP))
return msg->security;
+
+ /* honour pgp_autoinline */
+ prefer_inline = option(OPTPGPAUTOINLINE) ? INLINE : 0;
+ prefer_inline = ((msg->security & APPLICATION_PGP)
+ && (msg->security & (SIGN | ENCRYPT)))
+ ? (msg->security & INLINE) : prefer_inline;
+ msg->security |= prefer_inline;
snprintf (prompt, sizeof (prompt),
_("PGP (e)ncrypt, (s)ign, sign (a)s, (b)oth, %s, or (c)lear? "),