From 9b784ab8cf9f536959a6a41f37f3c35ec71a55d1 Mon Sep 17 00:00:00 2001 From: Gerd Moellmann Date: Thu, 15 Nov 2001 10:30:09 +0000 Subject: [PATCH] (direct_output_forward_char): Fix character/byte position comparison. --- src/ChangeLog | 5 +++++ src/dispnew.c | 4 ++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index 36850c4dbfd..c834525b5bf 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2001-11-15 Gerd Moellmann + + * dispnew.c (direct_output_forward_char): Fix character/byte + position comparison. + 2001-11-15 Miles Bader * editfns.c (find_field): Add BEG_LIMIT and END_LIMIT parameters. diff --git a/src/dispnew.c b/src/dispnew.c index f5dba1fd540..073fa2e53de 100644 --- a/src/dispnew.c +++ b/src/dispnew.c @@ -3724,8 +3724,8 @@ direct_output_forward_char (n) row = MATRIX_ROW (w->current_matrix, w->cursor.vpos); /* Give up if PT is outside of the last known cursor row. */ - if (PT <= MATRIX_ROW_START_BYTEPOS (row) - || PT >= MATRIX_ROW_END_BYTEPOS (row)) + if (PT <= MATRIX_ROW_START_CHARPOS (row) + || PT >= MATRIX_ROW_END_CHARPOS (row)) return 0; set_cursor_from_row (w, row, w->current_matrix, 0, 0, 0, 0); -- 2.39.5