From de3a95726540ffb4a3d2197f5581b684b8c3608f Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Sat, 15 Jan 2022 15:58:21 +0200 Subject: [PATCH] Fix setting cursor in pixel-scrolling modes * src/xdisp.c (redisplay_window): Don't set cursor to any glyph row past the one that contains EOB. (Bug#53275) --- src/xdisp.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/xdisp.c b/src/xdisp.c index 977d31703fb..c695e466e78 100644 --- a/src/xdisp.c +++ b/src/xdisp.c @@ -19157,7 +19157,8 @@ redisplay_window (Lisp_Object window, bool just_this_one_p) struct glyph_row *row; row = MATRIX_FIRST_TEXT_ROW (w->desired_matrix); - while (MATRIX_ROW_BOTTOM_Y (row) < new_vpos) + while (MATRIX_ROW_BOTTOM_Y (row) < new_vpos + && !row->ends_at_zv_p) ++row; TEMP_SET_PT_BOTH (MATRIX_ROW_START_CHARPOS (row), -- 2.39.2