]> git.eshelyaron.com Git - emacs.git/commitdiff
(forward_to_next_line_start): When taking the shortcut
authorGerd Moellmann <gerd@gnu.org>
Thu, 22 Feb 2001 13:56:35 +0000 (13:56 +0000)
committerGerd Moellmann <gerd@gnu.org>
Thu, 22 Feb 2001 13:56:35 +0000 (13:56 +0000)
at the start of the function, check that the \n in it->c is
from the iterator's current position.

src/ChangeLog
src/xdisp.c

index 5a8a8d06a0fa6af749ecc60c2ae31ae287e5b8e2..295595ea95bf2917540fd8cf3cb4d11083d8a2e3 100644 (file)
@@ -1,5 +1,9 @@
 2001-02-22  Gerd Moellmann  <gerd@gnu.org>
 
+       * xdisp.c (forward_to_next_line_start): When taking the shortcut
+       at the start of the function, check that the \n in it->c is
+       from the iterator's current position.
+       
        * xdisp.c (handle_single_display_prop): Add parameter
        DISPLAY_REPLACED_BEFORE_P.  If it is non-zero ignore display
        properties which replace the display of text with something else.
index 4782b3b0e070d16f7131fcae2d51823dc647da46..3da744c9c73d6a09cf48f2a86ba878a9e4375b76 100644 (file)
@@ -3517,7 +3517,9 @@ forward_to_next_line_start (it, skipped_p)
 
   /* If already on a newline, just consume it to avoid unintended
      skipping over invisible text below.  */
-  if (it->what == IT_CHARACTER && it->c == '\n')
+  if (it->what == IT_CHARACTER
+      && it->c == '\n'
+      && CHARPOS (it->position) == IT_CHARPOS (*it))
     {
       set_iterator_to_next (it, 0);
       it->c = 0;