aboutsummaryrefslogtreecommitdiffstats
path: root/src/nnn.c
diff options
context:
space:
mode:
authorGravatar Arun Prakash Jana <engineerarun@gmail.com>2020-01-17 20:26:14 +0530
committerGravatar Arun Prakash Jana <engineerarun@gmail.com>2020-01-17 20:26:14 +0530
commit5f18a0892c222f5efe28938c65d9a1ee8544b5a0 (patch)
tree7e3b887d773f1b99fd65b632995799f96a620896 /src/nnn.c
parent679374680fa8b961a30e5af47b779153f32734ad (diff)
downloadnnn-5f18a0892c222f5efe28938c65d9a1ee8544b5a0.tar.gz
Clear lastname is the top file is deleted
Diffstat (limited to 'src/nnn.c')
-rw-r--r--src/nnn.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/nnn.c b/src/nnn.c
index 43fd107..b415436 100644
--- a/src/nnn.c
+++ b/src/nnn.c
@@ -5279,7 +5279,8 @@ nochange:
if (cur && access(newpath, F_OK) == -1) {
move_cursor(cur - 1, 0);
copycurname();
- }
+ } else
+ lastname[0] = '\0';
if (cfg.filtermode)
presel = FILTER;