readline: fix backspace
This commit is contained in:
parent
69d4702696
commit
29017f7f7e
@ -539,6 +539,7 @@ int readline(char *buf, int size)
|
||||
if(key == '\b' && i>=1){
|
||||
buf[i-1] = '\0';
|
||||
i-=2;
|
||||
continue;
|
||||
}
|
||||
|
||||
buf[i] = key;
|
||||
|
Loading…
Reference in New Issue
Block a user