Index: ChangeLog =================================================================== RCS file: /sources/nmh/nmh/ChangeLog,v retrieving revision 1.278 diff -a -u -p -r1.278 ChangeLog --- ChangeLog 25 Jul 2008 01:07:39 -0000 1.278 +++ ChangeLog 25 Jul 2008 01:19:55 -0000 @@ -1,5 +1,14 @@ 2008-07-24 Eric Gillespie + * sbr/fmt_scan.c (fmt_scan): In the FT_LS_DECODE case, set value + non-zero if this field had contents, whether the contents needed + RFC 2047 decoding or not. + + * etc/replcomps, etc/replgroupcomps: Decode header fields for the + reply's header. + +2008-07-24 Eric Gillespie + * test/setup-test: Run 'make clean' before building 2008-07-24 Eric Gillespie Index: etc/replcomps =================================================================== RCS file: /sources/nmh/nmh/etc/replcomps,v retrieving revision 1.5 diff -a -u -p -r1.5 replcomps --- etc/replcomps 2 Jul 2003 02:01:50 -0000 1.5 +++ etc/replcomps 25 Jul 2008 01:19:55 -0000 @@ -5,22 +5,22 @@ %; %; If no To:/cc:/Fcc: text, we output empty fields for prompter to fill in. %; -%(lit)%(formataddr{reply-to})\ -%(formataddr %<{from}%(void{from})%|%(void{apparently-from})%>)\ -%(formataddr{resent-to})\ -%(formataddr{prev-resent-to})\ -%(formataddr{x-to})\ -%(formataddr{apparently-to})\ +%(lit)%(formataddr(decode{reply-to}))\ +%(formataddr %<{from}%(void(decode{from}))%|%(void(decode{apparently-from}))%>)\ +%(formataddr(decode{resent-to}))\ +%(formataddr(decode{prev-resent-to}))\ +%(formataddr(decode{x-to}))\ +%(formataddr(decode{apparently-to}))\ %(void(width))%(putaddr To: ) -%(lit)%(formataddr{to})\ -%(formataddr{cc})\ -%(formataddr{x-cc})\ -%(formataddr{resent-cc})\ -%(formataddr{prev-resent-cc})\ +%(lit)%(formataddr(decode{to}))\ +%(formataddr(decode{cc}))\ +%(formataddr(decode{x-cc}))\ +%(formataddr(decode{resent-cc}))\ +%(formataddr(decode{prev-resent-cc}))\ %(formataddr(me))\ %(void(width))%(putaddr cc: ) Fcc: %<{fcc}%{fcc}%|+outbox%> -Subject: %<{subject}Re: %{subject}%> +Subject: %<{subject}Re: %(decode{subject})%> %; %; Make References: and In-reply-to: fields for threading. %; Use (void), (trim) and (putstr) to eat trailing whitespace. Index: etc/replgroupcomps =================================================================== RCS file: /sources/nmh/nmh/etc/replgroupcomps,v retrieving revision 1.4 diff -a -u -p -r1.4 replgroupcomps --- etc/replgroupcomps 2 Jul 2003 02:01:50 -0000 1.4 +++ etc/replgroupcomps 25 Jul 2008 01:19:55 -0000 @@ -20,16 +20,16 @@ %; cc (and) %; personal address %; -%(lit)%(formataddr{mail-followup-to})\ +%(lit)%(formataddr(decode{mail-followup-to}))\ %<(nonnull)%(void(width))%(putaddr To: )\n\ %|\ -%(lit)%(formataddr %<{mail-reply-to}%?{reply-to}%?{from}%?{sender}%?{return-path}%>)\ +%(lit)%(formataddr %<(decode{mail-reply-to})%?(decode{reply-to})%?(decode{from})%?(decode{sender})%?(decode{return-path})%>)\ %<(nonnull)%(void(width))%(putaddr To: )\n%>\ -%(lit)%(formataddr{to})%(formataddr{cc})%(formataddr(me))\ +%(lit)%(formataddr(decode{to}))%(formataddr(decode{cc}))%(formataddr(me))\ %<(nonnull)%(void(width))%(putaddr cc: )\n%>%>\ %; Fcc: %<{fcc}%{fcc}%|+outbox%> -Subject: %<{subject}Re: %{subject}%> +Subject: %<{subject}Re: %(decode{subject})%> %; %; Make References: and In-reply-to: fields for threading. %; Use (void), (trim) and (putstr) to eat trailing whitespace. Index: sbr/fmt_scan.c =================================================================== RCS file: /sources/nmh/nmh/sbr/fmt_scan.c,v retrieving revision 1.25 diff -a -u -p -r1.25 fmt_scan.c --- sbr/fmt_scan.c 5 Apr 2008 18:41:37 -0000 1.25 +++ sbr/fmt_scan.c 25 Jul 2008 01:19:55 -0000 @@ -489,8 +489,11 @@ fmt_scan (struct format *format, char *s break; case FT_LS_DECODE: - if (str && decode_rfc2047(str, buffer2, sizeof(buffer2))) - str = buffer2; + if (str) { + if (decode_rfc2047(str, buffer2, sizeof(buffer2))) + str = buffer2; + value = 1; + } break; case FT_LS_TRIM: