Re: [PATCH] Don't let TUI exceptions escape to readline (PR tui/9765)

Tom Tromey
2020-01-10T14:42:03Z

>>>>> "Pedro" == Pedro Alves <palves@redhat.com> writes:

Pedro> gdb/ChangeLog:
Pedro> yyyy-mm-dd Pedro Alves <palves@redhat.com>

Pedro> PR tui/9765
Pedro> * tui/tui-io.c (tui_getc): Rename to ...
Pedro> (tui_getc_1): ... this.
Pedro> (tui_get): New, reimplent as try/catch wrapper around tui_getc_1.
Pedro> ---
Pedro> gdb/tui/tui-io.c | 31 ++++++++++++++++++++++++++++---
Pedro> 1 file changed, 28 insertions(+), 3 deletions(-)

This seems like a good idea measure to me.
Ideally I suppose these TUI functions shouldn't throw. However, in gdb
it can be difficult to ensure that, so this provides some defense.

thanks,
Tom