Commit Diff


commit - e38089df40061c544719ce8acbff850baceeef91
commit + 3e9a3ad7668453f4c045199e77dab38d86f65a0f
blob - 92cee602966ddb579499ce20c95544537dd361a2
blob + 518be41eaef7204abe7a6342a42c3bc009cb37de
--- rover.c
+++ rover.c
@@ -247,7 +247,8 @@ sync_signals()
         refresh();
         clear();
         rover.window = subwin(stdscr, LINES - 2, COLS, 1, 0);
-        SCROLL = MAX(ESEL - HEIGHT, 0);
+        if (HEIGHT < rover.nfiles && SCROLL + HEIGHT > rover.nfiles)
+            SCROLL = ESEL - HEIGHT;
         update_view();
         rover.pending_winch = 0;
     }