Key \ only works in empty prompt

This commit is contained in:
Arun Prakash Jana 2019-12-10 01:18:51 +05:30
parent a3d6b81d9f
commit 6582855412
No known key found for this signature in database
GPG Key ID: A75979F35C080412
1 changed files with 2 additions and 3 deletions

View File

@ -2074,13 +2074,12 @@ static int filterentries(char *path)
if (r == OK) {
/* Handle all control chars in main loop */
if ((*ch < ASCII_MAX && keyname(*ch)[0] == '^' && *ch != '^')
|| (*ch == '\\')) {
|| (*ch == '\\' && len == 1)) {
DPRINTF_D(*ch);
DPRINTF_S(keyname(*ch));
/* If there's a filter, try a command on ^P */
if (cfg.filtercmd && (*ch == CONTROL('P') || *ch == '\\')
&& len > 1) {
if (cfg.filtercmd && *ch == CONTROL('P') && len > 1) {
prompt_run(pln, (ndents ? dents[cur].name : ""), path);
/* Clear the prompt */