diff options
author | Tom Tromey <tromey@adacore.com> | 2022-06-23 11:05:39 -0600 |
---|---|---|
committer | Tom Tromey <tromey@adacore.com> | 2022-07-18 08:49:55 -0600 |
commit | 8f7f9b3a9142eeea50054b83e9bce12056bae6c9 (patch) | |
tree | 57131ab1a2db760f8d6e56bbb04cfd02cc8ae361 /gdb/infcall.c | |
parent | bbcab3366bc5269c2896e82ebd1b0f068ec9a50b (diff) | |
download | binutils-gdb-8f7f9b3a9142eeea50054b83e9bce12056bae6c9.tar.gz |
Remove ui_register_input_event_handler
This patch removes ui_register_input_event_handler and
ui_unregister_input_event_handler, replacing them with methods on
'ui'. It also changes gdb to use these methods everywhere, rather
than sometimes reaching in to the ui to manage the file descriptor
directly.
Diffstat (limited to 'gdb/infcall.c')
-rw-r--r-- | gdb/infcall.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/gdb/infcall.c b/gdb/infcall.c index 9334648ac0e..2acceed4b07 100644 --- a/gdb/infcall.c +++ b/gdb/infcall.c @@ -581,7 +581,7 @@ run_inferior_call (std::unique_ptr<call_thread_fsm> sm, ptid_t call_thread_ptid = call_thread->ptid; int was_running = call_thread->state == THREAD_RUNNING; - delete_file_handler (current_ui->input_fd); + current_ui->unregister_file_handler (); scoped_restore restore_in_infcall = make_scoped_restore (&call_thread->control.in_infcall, 1); @@ -624,9 +624,9 @@ run_inferior_call (std::unique_ptr<call_thread_fsm> sm, state again here. In other cases, stdin will be re-enabled by inferior_event_handler, when an exception is thrown. */ if (current_ui->prompt_state == PROMPT_BLOCKED) - delete_file_handler (current_ui->input_fd); + current_ui->unregister_file_handler (); else - ui_register_input_event_handler (current_ui); + current_ui->register_file_handler (); /* If the infcall does NOT succeed, normal_stop will have already finished the thread states. However, on success, normal_stop |