]> granicus.if.org Git - mutt/commitdiff
Add gpg signature name. (closes #3478)
authorKevin McCarthy <kevin@8t8.us>
Wed, 30 Oct 2013 01:25:52 +0000 (18:25 -0700)
committerKevin McCarthy <kevin@8t8.us>
Wed, 30 Oct 2013 01:25:52 +0000 (18:25 -0700)
Some mail clients display "noname" for the gpg signature
attachment.  This patch sets the mime name to "signature.asc".

The patch is based on
http://dev.mutt.org/trac/attachment/ticket/3478/gpg_signature_name.patch
with the changes:
  - removes the configuration options
  - removes mime description

crypt-gpgme.c
pgp.c

index cc22c94356a6d8e97c6419087534c9dbcf3b6493..44abe872814f8dca4c2f5bd2c752fb57ff9dd4df 100644 (file)
@@ -918,6 +918,7 @@ static BODY *sign_message (BODY *a, int use_smime)
   else
     {
       t->subtype = safe_strdup ("pgp-signature");
+      mutt_set_parameter ("name", "signature.asc", &t->parameter);
       t->use_disp = 0;
       t->disposition = DISPNONE;
       t->encoding = ENC7BIT;
diff --git a/pgp.c b/pgp.c
index 506a078d1329d3da3d587025aaad26a51dfbd75b..c0a5d8fa8e9083c116c82d853b9dcf0f16de086a 100644 (file)
--- a/pgp.c
+++ b/pgp.c
@@ -1127,6 +1127,7 @@ BODY *pgp_sign_message (BODY *a)
   t->disposition = DISPNONE;
   t->encoding = ENC7BIT;
   t->unlink = 1; /* ok to remove this file after sending. */
+  mutt_set_parameter ("name", "signature.asc", &t->parameter);
 
   return (a);
 }