]> git.eshelyaron.com Git - emacs.git/commitdiff
(verify_charstarts): Count right for continued lines.
authorRichard M. Stallman <rms@gnu.org>
Sun, 3 Apr 1994 02:04:38 +0000 (02:04 +0000)
committerRichard M. Stallman <rms@gnu.org>
Sun, 3 Apr 1994 02:04:38 +0000 (02:04 +0000)
src/dispnew.c

index 68e9423fcbdfee439da9413382d2453815733718..856659483a405c33a2a5fe94928c989839d1dcd2 100644 (file)
@@ -960,7 +960,15 @@ verify_charstarts (w)
       for (j = left; j < right; j++)
        if (charstart[j] > 0)
          last = charstart[j];
-      next_line = last + (BUF_ZV (XBUFFER (w->buffer)) != last);
+      /* Record where the next line should start.  */
+      next_line = last;
+      if (BUF_ZV (XBUFFER (w->buffer)) != last)
+       {
+         /* If there's a newline between the two lines, count that.  */
+         int endchar = *BUF_CHAR_ADDRESS (XBUFFER (w->buffer), last);
+         if (endchar == '\n')
+           next_line++;
+       }
     }
 }
 \f