[Tcsh] tcsh 6.24: broken escape handling
Christos Zoulas
christos at zoulas.com
Wed Nov 30 15:53:53 UTC 2022
Fix committed.
christos
> On Nov 29, 2022, at 7:46 PM, Christos Zoulas <christos at zoulas.com> wrote:
>
> I am able to reproduce this on cygwin, stay tuned for a fix.
>
> christos
>
>> On Nov 29, 2022, at 6:38 AM, Corinna Vinschen <vinschen at redhat.com> wrote:
>>
>> On Nov 29 12:04, H.Merijn Brand wrote:
>>> On Tue, 29 Nov 2022 11:42:23 +0100, Corinna Vinschen <vinschen at redhat.com> wrote:
>>>
>>>> On Nov 29 11:22, Corinna Vinschen wrote:
>>>>> Hi,
>>>>>
>>>>>
>>>>> I found a problem with ESC handling in tcsh 6.24. Consider this
>>>>> example: I have a machine called "pinky" and I'd like to see the machine
>>>>> name in the terminal header, so basically I perform this command via
>>>>> .login:
>>>>>
>>>>> echo "\033]0;pinky\007\c"
>>>>>
>>>>> With tcsh 6.22 I'm getting the desired result:
>>>>>
>>>>> $ echo "\033]0;pinky\007\c" [window title changes]
>>>>> $
>>>>>
>>>>> While with tcsh 6.24 the title still changes, there's something broken:
>>>>>
>>>>> $ echo "\033]0;pinky\007\c" [window title changes]
>>>>> "
>>>>> $
>>>>>
>>>>> That's with version 6.24.01 as well as with 6.24.02. On Linux
>>>>> I always get a quotation mark, on Cygwin the output is often a
>>>>> quotation mark, sometimes random garbage. The output depends
>>>>> on the string to print, but it always contains at least one LF:
>>>>>
>>>>> $ echo "\033]0;pin\007\c" [window title changes]
>>>>>
>>>>> $
>>>>>
>>>>> Sorry for noticing this problem so late, but I'm neither running this
>>>>> sequence by default on Cygwin, nor on Linux. It occured to me only
>>>>> because I updated a seldomly used laptop lately, called pinky, FWIW :}
>>>>
>>>> I bisected the problem and it looks like this commit is the culprit,
>>>> introducing this problem for the first time:
>>>>
>>>> 06915a414e18 echo parse escape enhancements (H.Merijn Brand)
>>>
>>> % grep cwdcmd ~/.tcshrc | cat -ve
>>> alias cwdcmd 'glob "^[]0;'${LOGNAME}'@'${HOST}':$cwd ['$$':'$tty']^G"'$
>>>
>>> ^^^ That still works
>>
>> Yeah, but that doesn't change the fact that 06915a414e18 broke at
>> least handling of the ESC ] 0 sequence, and the result looks like
>> a buffer overrun.
>>
>>
>> Corinna
>>
>> --
>> Tcsh mailing list
>> Tcsh at astron.com <mailto:Tcsh at astron.com>
>> https://mailman.astron.com/mailman/listinfo/tcsh
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mailman.astron.com/pipermail/tcsh/attachments/20221130/2d8c8d39/attachment-0001.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 235 bytes
Desc: Message signed with OpenPGP
URL: <https://mailman.astron.com/pipermail/tcsh/attachments/20221130/2d8c8d39/attachment-0001.asc>
More information about the Tcsh
mailing list