Code

Fix scrolling when current line is outside of splitted view
authorJonas Fonseca <fonseca@diku.dk>
Fri, 12 May 2006 10:32:22 +0000 (12:32 +0200)
committerJonas Fonseca <fonseca@antimatter.localdomain>
Fri, 12 May 2006 10:32:22 +0000 (12:32 +0200)
tig.c

diff --git a/tig.c b/tig.c
index c210699c4a83e15321f6573830f6d6831ce33d62..eb7373c96f0450c7c5f10d4ff1dc2f8d0d9bf3e5 100644 (file)
--- a/tig.c
+++ b/tig.c
@@ -1153,7 +1153,7 @@ open_view(struct view *prev, enum request request, enum open_flags flags)
 
        resize_display();
 
-       if (split && prev->lineno - prev->offset > prev->height) {
+       if (split && prev->lineno - prev->offset >= prev->height) {
                /* Take the title line into account. */
                int lines = prev->lineno - prev->height + 1;