[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Fwd: Strange-Dangerous behaviour in Cygwin]
From: |
Jim Meyering |
Subject: |
Re: [Fwd: Strange-Dangerous behaviour in Cygwin] |
Date: |
Sat, 07 May 2005 19:24:29 +0200 |
Eric Blake <address@hidden> wrote:
> Relevant clips from this cygwin bug report. When tty settings are weird
> (I'm not sure whether the bug is in cygwin, xterm, or just bad tty
> settings that could be reproduced elsewhere), backspace only repositions
> the cursor on screen, so that the actual buffer read by yesno() can
> contain "y\bn" instead of "n". Is it possible for lib/yesno.c to be a
> little more paranoid and check that there are not embedded characters
> normally used in terminal editing that would undo the first character?
I don't think changing yesno would be appropriate in this case.
What if the string is "n\by"?
What if \b is not the erase character?
What if the string is "yes" and `e' is the `erase' character?
Should it handle both DEL and ERASE characters?
Should it also handle word-erase and line-erase characters?
I know you said `normally used...', so I assume you wanted
something simple, befitting yesno's status, but I don't see
an appropriate way to solve the problem by changing yesno.
Alternative opinions (or patches to yesno.c) welcome.