From 26f44f0dfcf5e4e9c92aef65d323c4b39418a61c Mon Sep 17 00:00:00 2001 From: Arun Prakash Jana Date: Fri, 16 Jul 2021 11:09:20 +0530 Subject: [PATCH] Fix selection in / --- src/nnn.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/nnn.c b/src/nnn.c index 598d78db..d0334f5a 100644 --- a/src/nnn.c +++ b/src/nnn.c @@ -1752,8 +1752,9 @@ static void rmfromselbuf(size_t len) static int scanselforpath(const char *path, bool getsize) { if (!path[1]) { /* path should always be at least two bytes (including NULL) */ + g_buf[0] = '/'; findselpos = pselbuf; - return TRUE; + return 1; /* Length of '/' is 1 */ } size_t off = xstrsncpy(g_buf, path, PATH_MAX);