From eea4d34423f3b1aabebcd36ba707a25a4780f990 Mon Sep 17 00:00:00 2001 From: Arun Prakash Jana Date: Mon, 26 Apr 2021 07:31:15 +0530 Subject: [PATCH] Fix build break --- src/nnn.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/nnn.c b/src/nnn.c index ddff97e0..9ab807c3 100644 --- a/src/nnn.c +++ b/src/nnn.c @@ -6070,10 +6070,8 @@ nochange: #if NCURSES_MOUSE_VERSION > 1 /* Scroll up */ if (event.bstate == BUTTON4_PRESSED && ndents && (cfg.rollover || cur)) { - if (!cfg.rollover && cur < scroll_lines) - move_cursor(0, 0); - else - move_cursor((cur + ndents - scroll_lines) % ndents, 0); + move_cursor((!cfg.rollover && cur < scroll_lines + ? 0 : (cur + ndents - scroll_lines) % ndents), 0); break; }