X-Git-Url: http://git.madism.org/?p=apps%2Fmadmutt.git;a=blobdiff_plain;f=crypt-gpgme.c;h=b9b7613c4421bdccbd02940d33c67a36cce686e5;hp=03eb846583a87b33cd8155d5a40c23020bb8a912;hb=fe23f004535336d4d6103eada14a59173c212edb;hpb=5251a17c26fadd6559295f6962f831a97eeeefdb diff --git a/crypt-gpgme.c b/crypt-gpgme.c index 03eb846..b9b7613 100644 --- a/crypt-gpgme.c +++ b/crypt-gpgme.c @@ -3827,21 +3827,23 @@ static int gpgme_send_menu (HEADER * msg, int *redraw, int is_smime) if (is_smime) choice = mutt_multi_choice (_ - ("S/MIME (e)ncrypt, (s)ign, sign (a)s, (b)oth, (t)oggle or (f)orget it?"), - _("esabtf")); + ("S/MIME (e)ncrypt, (s)ign, sign (a)s, (b)oth, (p)gp or (c)lear?"), + _("esabpfc")); else choice = mutt_multi_choice (_ - ("PGP (e)ncrypt, (s)ign, sign (a)s, (b)oth, (t)oggle or (f)orget it?"), - _("esabtf")); + ("PGP (e)ncrypt, (s)ign, sign (a)s, (b)oth, s/(m)ime or (c)lear?"), + _("esabmfc")); switch (choice) { case 1: /* (e)ncrypt */ msg->security |= (is_smime ? SMIMEENCRYPT : PGPENCRYPT); + msg->security &= ~(is_smime ? SMIMESIGN : PGPSIGN); break; case 2: /* (s)ign */ msg->security |= (is_smime ? SMIMESIGN : PGPSIGN); + msg->security &= ~(is_smime ? SMIMEENCRYPT : PGPENCRYPT); break; case 3: /* sign (a)s */ @@ -3856,9 +3858,11 @@ static int gpgme_send_menu (HEADER * msg, int *redraw, int is_smime) msg->security |= (is_smime ? SMIMESIGN : PGPSIGN); } +#if 0 else { msg->security &= (is_smime ? ~SMIMESIGN : ~PGPSIGN); } +#endif *redraw = REDRAW_FULL; break; @@ -3867,16 +3871,16 @@ static int gpgme_send_menu (HEADER * msg, int *redraw, int is_smime) (is_smime ? (SMIMEENCRYPT | SMIMESIGN) : (PGPENCRYPT | PGPSIGN)); break; - case 5: /* (t)oggle */ + case 5: /* (p)gp or s/(m)ime */ is_smime = !is_smime; break; - case 6: /* (f)orget it */ + case 6: /* (c)lear */ msg->security = 0; break; } - if (choice == 6); + if (choice == 6 || choice == 7); else if (is_smime) { msg->security &= ~APPLICATION_PGP; msg->security |= APPLICATION_SMIME;