This is the mail archive of the
cygwin-cvs@cygwin.com
mailing list for the Cygwin project.
[newlib-cygwin] Cygwin: don't move cursor on NUL char at all
- From: Corinna Vinschen <corinna at sourceware dot org>
- To: cygwin-cvs at sourceware dot org
- Date: 21 Feb 2020 09:31:34 -0000
- Subject: [newlib-cygwin] Cygwin: don't move cursor on NUL char at all
https://sourceware.org/git/gitweb.cgi?p=newlib-cygwin.git;h=db33f3499cb1c74d56a521ea2d18084073b14840
commit db33f3499cb1c74d56a521ea2d18084073b14840
Author: Corinna Vinschen <corinna@vinschen.de>
Date: Fri Feb 21 10:26:25 2020 +0100
Cygwin: don't move cursor on NUL char at all
Add a comment instead to explain that this behaviour contradicts
the terminfo entry.
Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
Diff:
---
winsup/cygwin/fhandler_console.cc | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/winsup/cygwin/fhandler_console.cc b/winsup/cygwin/fhandler_console.cc
index f7044c8..42040a9 100644
--- a/winsup/cygwin/fhandler_console.cc
+++ b/winsup/cygwin/fhandler_console.cc
@@ -2733,8 +2733,9 @@ do_print:
cursor_rel (-1, 0);
break;
case IGN:
- if (!wincap.has_con_24bit_colors () || con_is_legacy)
- cursor_rel (1, 0);
+ /* Up to release 3.1.3 we called cursor_rel (1, 0); to move the cursor
+ one step to the right. However, that neither matches the terminfo
+ for the cygwin terminal, nor the one for the xterm terminal. */
break;
case CR:
cursor_get (&x, &y);