From 8692ca9275b6425dcbc9145bf556381ba2f8567e Mon Sep 17 00:00:00 2001 From: Gerd Moellmann Date: Thu, 18 Jan 2001 12:29:55 +0000 Subject: [PATCH] (forward_to_next_line_start): Stop at end of buffer when searching for a newline. --- src/ChangeLog | 7 +++++++ src/xdisp.c | 3 ++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/src/ChangeLog b/src/ChangeLog index cd4c4d0cf42..f30ccf975b2 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,10 @@ +2001-01-18 Gerd Moellmann + + * xterm.c (x_initialize): Set char_ins_del_ok to 1. + + * xdisp.c (forward_to_next_line_start): Stop at end of buffer + when searching for a newline. + 2001-01-18 Kenichi Handa * xdisp.c (display_string): Fix previous change. diff --git a/src/xdisp.c b/src/xdisp.c index 6ca639bcbfa..2354eaa6209 100644 --- a/src/xdisp.c +++ b/src/xdisp.c @@ -3511,7 +3511,8 @@ forward_to_next_line_start (it, skipped_p) !newline_found_p && n < MAX_NEWLINE_DISTANCE; n += STRINGP (it->string) ? 0 : 1) { - get_next_display_element (it); + if (!get_next_display_element (it)) + break; newline_found_p = it->what == IT_CHARACTER && it->c == '\n'; set_iterator_to_next (it, 0); } -- 2.39.5