This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH] Fix truncation of TUI command history
- From: Pedro Alves <palves at redhat dot com>
- To: Patrick Palka <patrick at parcs dot ath dot cx>, gdb-patches at sourceware dot org
- Date: Thu, 04 Sep 2014 10:44:35 +0100
- Subject: Re: [PATCH] Fix truncation of TUI command history
- Authentication-results: sourceware.org; auth=none
- References: <1409422278-19284-1-git-send-email-patrick at parcs dot ath dot cx>
Hi Patrick,
On 08/30/2014 07:11 PM, Patrick Palka wrote:
> index aa14790..eee5f1ac6 100644
> --- a/gdb/tui/tui-io.c
> +++ b/gdb/tui/tui-io.c
> @@ -678,8 +678,9 @@ tui_getc (FILE *fp)
> }
> else
> {
> + /* Move cursor to the end of the command line. */
> wmove (w, TUI_CMD_WIN->detail.command_info.cur_line,
> - TUI_CMD_WIN->detail.command_info.curch);
> + strlen (tui_rl_saved_prompt) + rl_end);
> waddch (w, ch);
Does this still do the right thing with secondary prompts?
E.g., if you do "quit" while a program is running, and then
press enter a few times just to have the query repeat (and
then pagination kick in, for extra stress).
Thanks,
Pedro Alves