Arun Prakash Jana
5 years ago
No known key found for this signature in database
GPG Key ID: A75979F35C080412
1 changed files with
6 additions and
2 deletions
-
src/nnn.c
|
@@ -2412,8 +2412,12 @@ static char *xreadline(const char *prefill, const char *prompt) |
|
|
case CONTROL('D'): |
|
|
case CONTROL('D'): |
|
|
if (pos < len) |
|
|
if (pos < len) |
|
|
++pos; |
|
|
++pos; |
|
|
else |
|
|
|
|
|
continue; // fallthrough |
|
|
|
|
|
|
|
|
else if (!(pos || len)) { /* Exit on ^D at empty prompt */ |
|
|
|
|
|
len = 0; |
|
|
|
|
|
goto END; |
|
|
|
|
|
} else |
|
|
|
|
|
continue; |
|
|
|
|
|
// fallthrough |
|
|
case 127: // fallthrough |
|
|
case 127: // fallthrough |
|
|
case '\b': /* rhel25 sends '\b' for backspace */ |
|
|
case '\b': /* rhel25 sends '\b' for backspace */ |
|
|
if (pos > 0) { |
|
|
if (pos > 0) { |
|
|