diff --git a/src/nnn.c b/src/nnn.c index 3d866bf4..1ab79d20 100644 --- a/src/nnn.c +++ b/src/nnn.c @@ -3321,9 +3321,9 @@ static int filterentries(char *path, char *lastname) * - new matches can only be a subset of current matches. */ /* ndents = total; */ - - if (matches(pln) == -1) { - showfilter(ln); + r = matches(pln); + if (r <= 0) { + !r ? unget_wch(KEY_BACKSPACE) : showfilter(ln); continue; }