forked from test34/can_wizard
fix masking input when there is no hintsCallback
from orig commit ec5e4e8
This commit is contained in:
parent
f19803a5fa
commit
d64bc6bd87
1 changed files with 2 additions and 1 deletions
|
@ -593,7 +593,8 @@ int linenoiseEditInsert(struct linenoiseState *l, char c) {
|
|||
if ((!mlmode && l->plen+l->len < l->cols && !hintsCallback)) {
|
||||
/* Avoid a full update of the line in the
|
||||
* trivial case. */
|
||||
if (fwrite(&c,1,1,stdout) == -1) return -1;
|
||||
char d = (maskmode==1) ? '*' : c;
|
||||
if (fwrite(&d,1,1,stdout) == -1) return -1;
|
||||
} else {
|
||||
refreshLine(l);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue