diff options
author | Pedro Alves <palves@redhat.com> | 2018-01-30 14:23:51 +0000 |
---|---|---|
committer | Pedro Alves <palves@redhat.com> | 2018-01-30 14:23:51 +0000 |
commit | 9c3a5d9319648db16b30a91253ad02d41d242cef (patch) | |
tree | c2d7020fdcdc0e3951989f6606298f320b10db05 /gdb/inflow.h | |
parent | 040b4a9eb8430dc5e0fc657da88b08ab730b97ee (diff) | |
download | fsf-binutils-gdb-9c3a5d9319648db16b30a91253ad02d41d242cef.zip fsf-binutils-gdb-9c3a5d9319648db16b30a91253ad02d41d242cef.tar.gz fsf-binutils-gdb-9c3a5d9319648db16b30a91253ad02d41d242cef.tar.bz2 |
linux-nat: Eliminate custom target_terminal_{inferior,ours}, stop using set_sigint_trap
This patch gets rid of linux-nat.c's custom
target_terminal_inferior/target_terminal_ours implementations.
The only remaining reason those overrides exist is to install
clear_sigint_trap in order to pass Ctrl-C/SIGINT to the inferior
process in case the inferior is not sharing GDB's terminal (and
target_wait was called without TARGET_WNOHANG).
However, I think that's better handled by QUIT / target_pass_ctrlc
nowadays. Going that route avoids the issue with set_sigint_trap only
looking at the current inferior to know whether to override SIGINT or
not, which doesn't really work correctly with multi-inferior in the
picture. Also centralizing on a single SIGINT handler as much as
possible seems better considering a future multi-target world.
Tested on x86-64 GNU/Linux.
gdb/ChangeLog:
2018-01-30 Pedro Alves <palves@redhat.com>
* linux-nat.c (wait_for_signal): New function.
(wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
directly.
(async_terminal_is_ours)
(linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
(linux_nat_add_target): Don't override
to_terminal_inferior/to_terminal_ours.
Diffstat (limited to 'gdb/inflow.h')
0 files changed, 0 insertions, 0 deletions