forked from test34/can_wizard
Set seq to empty string if color/bold not used
Added changes from commit b12f6ba (orig)
This commit is contained in:
parent
e17520f632
commit
33296225b5
1 changed files with 2 additions and 0 deletions
|
@ -411,6 +411,8 @@ void refreshShowHints(struct abuf *ab, struct linenoiseState *l, int plen) {
|
||||||
if (bold == 1 && color == -1) color = 37;
|
if (bold == 1 && color == -1) color = 37;
|
||||||
if (color != -1 || bold != 0)
|
if (color != -1 || bold != 0)
|
||||||
snprintf(seq,64,"\033[%d;%d;49m",bold,color);
|
snprintf(seq,64,"\033[%d;%d;49m",bold,color);
|
||||||
|
else
|
||||||
|
seq[0] = '\0';
|
||||||
abAppend(ab,seq,strlen(seq));
|
abAppend(ab,seq,strlen(seq));
|
||||||
abAppend(ab,hint,hintlen);
|
abAppend(ab,hint,hintlen);
|
||||||
if (color != -1 || bold != 0)
|
if (color != -1 || bold != 0)
|
||||||
|
|
Loading…
Reference in a new issue