+ /* remember optional Charset: armor header as defined by RfC4880 */
+ if (mutt_strncmp ("Charset: ", buf, 9) == 0)
+ {
+ size_t l = 0;
+ gpgcharset = safe_strdup (buf + 9);
+ if ((l = mutt_strlen (gpgcharset)) > 0 && gpgcharset[l-1] == '\n')
+ gpgcharset[l-1] = 0;
+ if (mutt_check_charset (gpgcharset, 0) < 0)
+ mutt_str_replace (&gpgcharset, "UTF-8");
+ }