From: Arun Prakash Jana Date: Sun, 5 Apr 2020 09:12:32 +0000 (+0530) Subject: Fix jump on canceled duplicate X-Git-Tag: v3.1~21 X-Git-Url: http://www.git.stargrave.org/?a=commitdiff_plain;h=078d05dc7a0e3ae331a4eaae07a644fe9cde56ee;p=nnn.git Fix jump on canceled duplicate --- diff --git a/src/nnn.c b/src/nnn.c index d5421695..f4224a14 100644 --- a/src/nnn.c +++ b/src/nnn.c @@ -6042,9 +6042,11 @@ nochange: /* Skip renaming to same name */ if (strcmp(tmp, dents[cur].name) == 0) { tmp = xreadline(dents[cur].name, messages[MSG_COPY_NAME]); - if (strcmp(tmp, dents[cur].name) == 0) + if (!tmp || !tmp[0] || !strcmp(tmp, dents[cur].name)) { + cfg.filtermode ? presel = FILTER : statusbar(path); + copycurname(); goto nochange; - + } ret = 'd'; } break;