summaryrefslogtreecommitdiff
path: root/src/dispnew.c
diff options
context:
space:
mode:
authorEli Zaretskii <eliz@gnu.org>2011-11-12 12:09:38 +0200
committerEli Zaretskii <eliz@gnu.org>2011-11-12 12:09:38 +0200
commit1e5b2111b6ebfa6f8e244add939de453e9feafe6 (patch)
tree3017807f69469c1bfdf3b2fc0ce4181648ffa60c /src/dispnew.c
parent89d612214e95564c06c775189f8994001e3e1c06 (diff)
downloademacs-1e5b2111b6ebfa6f8e244add939de453e9feafe6.tar.gz
dispnew.c (scrolling_window): Fix index usage.
src/dispnew.c (scrolling_window): Fix incorrect indices in accessing current_matrix and desired_matrix. (Bug#9990)
Diffstat (limited to 'src/dispnew.c')
-rw-r--r--src/dispnew.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/dispnew.c b/src/dispnew.c
index 46d1917b144..dafb8127eb3 100644
--- a/src/dispnew.c
+++ b/src/dispnew.c
@@ -4334,10 +4334,10 @@ scrolling_window (struct window *w, int header_line_p)
j = last_old;
while (i - 1 > first_new
&& j - 1 > first_old
- && MATRIX_ROW (current_matrix, i - 1)->enabled_p
- && (MATRIX_ROW (current_matrix, i - 1)->y
- == MATRIX_ROW (desired_matrix, j - 1)->y)
- && !MATRIX_ROW (desired_matrix, j - 1)->redraw_fringe_bitmaps_p
+ && MATRIX_ROW (current_matrix, j - 1)->enabled_p
+ && (MATRIX_ROW (current_matrix, j - 1)->y
+ == MATRIX_ROW (desired_matrix, i - 1)->y)
+ && !MATRIX_ROW (desired_matrix, i - 1)->redraw_fringe_bitmaps_p
&& row_equal_p (MATRIX_ROW (desired_matrix, i - 1),
MATRIX_ROW (current_matrix, j - 1), 1))
--i, --j;