commit ebd1f5efb0ec56ee63bd413a20f4b13646df53e0
parent 64aff3e2ee70027eb7c0587b2723b34a32027643
Author: Markus Rinne <markus.ka.rinne@gmail.com>
Date: Mon, 25 Nov 2024 13:31:56 +0200
Clear screen: Fix edge case
With sequence \e[1J, if cursor is on second line, clear the first line.
Diffstat:
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/st.c b/st.c
@@ -1767,7 +1767,7 @@ csihandle(void)
}
break;
case 1: /* above */
- if (term.c.y > 1)
+ if (term.c.y > 0)
tclearregion(0, 0, term.col-1, term.c.y-1);
tclearregion(0, term.c.y, term.c.x, term.c.y);
break;