]> granicus.if.org Git - neomutt/commitdiff
RFC2047 encode/decode the group name in an address list. closes #3317
authorMichael Elkins <me@mutt.org>
Thu, 23 Sep 2010 18:06:29 +0000 (11:06 -0700)
committerMichael Elkins <me@mutt.org>
Thu, 23 Sep 2010 18:06:29 +0000 (11:06 -0700)
rfc2047.c

index 7a117118ca3e0a003e0cbe26f2a4a0eac28e2685..2927b6f5d59c6ac69b89027b86fa590bd2017f2f 100644 (file)
--- a/rfc2047.c
+++ b/rfc2047.c
@@ -614,6 +614,8 @@ void rfc2047_encode_adrlist (ADDRESS *addr, const char *tag)
   {
     if (ptr->personal)
       _rfc2047_encode_string (&ptr->personal, 1, col);
+    else if (ptr->group && ptr->mailbox)
+      _rfc2047_encode_string (&ptr->mailbox, 1, col);
 #ifdef EXACT_ADDRESS
     if (ptr->val)
       _rfc2047_encode_string (&ptr->val, 1, col);
@@ -910,6 +912,8 @@ void rfc2047_decode_adrlist (ADDRESS *a)
     if (a->personal && ((strstr (a->personal, "=?") != NULL) || 
                        (AssumedCharset && *AssumedCharset)))
       rfc2047_decode (&a->personal);
+    else if (a->group && a->mailbox && (strstr (a->mailbox, "=?") != NULL))
+      rfc2047_decode (&a->mailbox);
 #ifdef EXACT_ADDRESS
     if (a->val && strstr (a->val, "=?") != NULL)
       rfc2047_decode (&a->val);