]> granicus.if.org Git - neomutt/commitdiff
fix gpgme S/MIME non-detached signature handling 662/head
authorStefan Bühler <stbuehler@web.de>
Tue, 4 Jul 2017 09:57:24 +0000 (11:57 +0200)
committerRichard Russon <rich@flatcap.org>
Thu, 6 Jul 2017 10:56:56 +0000 (11:56 +0100)
- gpgsm ends the session after the decrypt error, so restart gpgsm when
  retrying with "maybe_signed".
- evolution sends encrypted + signed S/MIME mails with non-detached
  signatures

ncrypt/crypt_gpgme.c

index f221c5699cadde13c4abc16506ce0fcd22c424ab..d4a7564e7db663dd1626c5bbd6cec541fb39788d 100644 (file)
@@ -1705,6 +1705,9 @@ restart:
       {
         maybe_signed = true;
         gpgme_data_release(plaintext);
+        /* gpgsm ends the session after an error; restart it */
+        gpgme_release(ctx);
+        ctx = create_gpgme_context(is_smime);
         goto restart;
       }
     }