client: Rewrite workaround for readline
Instead of calling display(""), explicitly use the sequence of commands to force readline to properly update its internal state and re-display the prompt.
This commit is contained in:
parent
848897ec17
commit
61e8a640b1
|
@ -534,7 +534,14 @@ void display_enable_cmd_prompt(void)
|
||||||
|
|
||||||
rl_set_prompt(IWD_PROMPT);
|
rl_set_prompt(IWD_PROMPT);
|
||||||
|
|
||||||
display("");
|
/*
|
||||||
|
* The following sequence of rl_* commands forces readline to properly
|
||||||
|
* update its internal state and re-display the new prompt.
|
||||||
|
*/
|
||||||
|
rl_save_prompt();
|
||||||
|
rl_redisplay();
|
||||||
|
rl_restore_prompt();
|
||||||
|
rl_forced_update_display();
|
||||||
}
|
}
|
||||||
|
|
||||||
void display_disable_cmd_prompt(void)
|
void display_disable_cmd_prompt(void)
|
||||||
|
|
Loading…
Reference in New Issue