From 110a4eb108586fb1e2c3e05e17bd0e9f5fbf9b42 Mon Sep 17 00:00:00 2001 From: Arun Prakash Jana Date: Sun, 2 Aug 2020 00:54:07 +0530 Subject: [PATCH] Avoid redundant printw() call for order --- src/nnn.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/nnn.c b/src/nnn.c index 08327a21..b6557399 100644 --- a/src/nnn.c +++ b/src/nnn.c @@ -5188,9 +5188,8 @@ static void statusbar(char *path) } else { /* light or detail mode */ char sort[] = "\0\0\0\0\0"; - getorderstr(sort); - - printw("%s", sort); + if (getorderstr(sort)) + printw("%s", sort); /* Timestamp */ print_time(&pent->t);