aboutsummaryrefslogtreecommitdiff
path: root/gdb/remote.c
diff options
context:
space:
mode:
authorSimon Marchi <simon.marchi@polymtl.ca>2020-07-02 08:37:26 -0400
committerSimon Marchi <simon.marchi@polymtl.ca>2020-07-02 08:40:44 -0400
commitb1a35af2704842ff1a90626b0148c0fc93f995f6 (patch)
treefb09d71b294283fbdf1238486ffe0a35fe8bb884 /gdb/remote.c
parent0942c7ab94e554657c3e11ab85ae7f15373ee80d (diff)
downloadgdb-b1a35af2704842ff1a90626b0148c0fc93f995f6.zip
gdb-b1a35af2704842ff1a90626b0148c0fc93f995f6.tar.gz
gdb-b1a35af2704842ff1a90626b0148c0fc93f995f6.tar.bz2
gdb: remove unused fetch_inferior_event and inferior_event_handler parameters
I noticed that fetch_inferior_event receives the client_data parameter from its caller, inferior_event_handler, but doesn't actually need it. This patch removes it. In turn, inferior_event_handler doesn't use its parameter, so remove it too. The `data` argument used when registering remote_async_inferior_event_handler is changed to NULL, to avoid confusion. It could make people think that the value passed is used somewhere, when in fact it's not. gdb/ChangeLog: * inf-loop.c (inferior_event_handler): Remove client_data param. * inf-loop.h (inferior_event_handler): Likewise. * infcmd.c (step_1): Adjust. * infrun.c (proceed): Adjust. (fetch_inferior_event): Remove client_data param. (infrun_async_inferior_event_handler): Adjust. * infrun.h (fetch_inferior_event): Remove `void *` param. * linux-nat.c (handle_target_event): Adjust. * record-btrace.c (record_btrace_handle_async_inferior_event): Adjust. * record-full.c (record_full_async_inferior_event_handler): Adjust. * remote.c (remote_async_inferior_event_handler): Adjust. Change-Id: I3c2aa1eb0ea3e0985df096660d2dcd794674f2ea
Diffstat (limited to 'gdb/remote.c')
-rw-r--r--gdb/remote.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/gdb/remote.c b/gdb/remote.c
index d560c69..f7f99dc 100644
--- a/gdb/remote.c
+++ b/gdb/remote.c
@@ -5605,8 +5605,7 @@ remote_target::open_1 (const char *name, int from_tty, int extended_p)
/* Register extra event sources in the event loop. */
rs->remote_async_inferior_event_token
- = create_async_event_handler (remote_async_inferior_event_handler,
- remote);
+ = create_async_event_handler (remote_async_inferior_event_handler, NULL);
rs->notif_state = remote_notif_state_allocate (remote);
/* Reset the target state; these things will be queried either by
@@ -14158,13 +14157,13 @@ remote_async_serial_handler (struct serial *scb, void *context)
{
/* Don't propogate error information up to the client. Instead let
the client find out about the error by querying the target. */
- inferior_event_handler (INF_REG_EVENT, NULL);
+ inferior_event_handler (INF_REG_EVENT);
}
static void
remote_async_inferior_event_handler (gdb_client_data data)
{
- inferior_event_handler (INF_REG_EVENT, data);
+ inferior_event_handler (INF_REG_EVENT);
}
int