Subject: bug#12792: 24.2.50; shell-mode renders all its output in a yellow face

From: Wolfgang Jenkner <[email-masked]>
Date: Sat, 03 Nov 2012 18:59:25 +0100

On Sat, Nov 03 2012, Eli Zaretskii wrote:

>> In bug#11883 you give this example
>> 
>> echo -e "\033[31mtest\033[39m"
>> 
>> but ansi-color has never supported SGR parameter 39.  However, before my
>> change (the latter commit above), any unknown parameter would have the
>> same effect as parameter 0 (turn off all rendition aspects), while it is
>> simply ignored now (well, except for an "Invalid face reference: nil"
>> message), see `ansi-color-apply-sequence'.  Perhaps, this explains the
>> problem.
>
> SGR parameter 39 means go back to the default foreground color.  How
> can ansi-color not support it and still be useful?

Perhaps because that parameter is but rarely observed in the wild?

> IIUC, what the old
> code did was exactly the right thing (or at least close, since 0 means
> turn off _all_ attributes, not just the foreground color), so removing
> it without replacing it with something that restores the default
> foreground would be a bug, IMO.

I'll fix this omission if nobody beats me to it.

Wolfgang