nnn

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | README | LICENSE

commit 8959a5b57dd75a0a0402fedd7a3705146631d419
parent 0d88940ba56fc66874b5c43f7aaef8e20f99d26c
Author: Vlad Glagolev <vaygr@users.noreply.github.com>
Date:   Sat,  7 Oct 2017 23:47:32 -0400

Correct name checking for NEW and RENAME (#53)


Diffstat:
Mnnn.c | 4++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/nnn.c b/nnn.c @@ -2677,7 +2677,7 @@ nochange: break; /* Allow only relative, same dir paths */ - if (tmp[0] == '/' || basename(tmp) != tmp) { + if (tmp[0] == '/' || xstrcmp(basename(tmp), tmp) != 0) { printmsg(STR_INPUT); goto nochange; } @@ -2730,7 +2730,7 @@ nochange: break; /* Allow only relative, same dir paths */ - if (tmp[0] == '/' || basename(tmp) != tmp) { + if (tmp[0] == '/' || xstrcmp(basename(tmp), tmp) != 0) { printmsg(STR_INPUT); goto nochange; }