aboutsummaryrefslogtreecommitdiff
path: root/gdb/remote-notif.h
diff options
context:
space:
mode:
authorTom Tromey <tom@tromey.com>2019-01-06 13:30:00 -0700
committerTom Tromey <tom@tromey.com>2019-01-14 17:32:24 -0700
commitbb27775165d9b992120371383012404e213b1981 (patch)
tree61d3ff87dfb04c5ea6d43f20f7bda37987e9fd12 /gdb/remote-notif.h
parent05be00a884850c5fe314004c9b91609f480308f6 (diff)
downloadgdb-bb27775165d9b992120371383012404e213b1981.zip
gdb-bb27775165d9b992120371383012404e213b1981.tar.gz
gdb-bb27775165d9b992120371383012404e213b1981.tar.bz2
Constify some remote-notif functions
This constifies the "buf" arguments to various remote-notif functions and updates the users. gdb/ChangeLog 2019-01-14 Tom Tromey <tom@tromey.com> * remote-notif.c (handle_notification, remote_notif_ack) (remote_notif_parse): Make "buf" const. * remote-notif.h (struct notif_client) <parse, ack>: Make "buf" const. (remote_notif_parse, remote_notif_ack, handle_notification): Likewise. * remote.c (remote_notif_stop_parse): Make "buf" const. (remote_target::remote_parse_stop_reply): Make "buf" const. (remote_notif_stop_ack): Make "buf" const.
Diffstat (limited to 'gdb/remote-notif.h')
-rw-r--r--gdb/remote-notif.h11
1 files changed, 6 insertions, 5 deletions
diff --git a/gdb/remote-notif.h b/gdb/remote-notif.h
index a4a931b..7973ad7 100644
--- a/gdb/remote-notif.h
+++ b/gdb/remote-notif.h
@@ -55,13 +55,13 @@ typedef struct notif_client
function may throw exception if contents in BUF is not the
expected event. */
void (*parse) (remote_target *remote,
- struct notif_client *self, char *buf,
+ struct notif_client *self, const char *buf,
struct notif_event *event);
/* Send field <ack_command> to remote, and do some checking. If
something wrong, throw an exception. */
void (*ack) (remote_target *remote,
- struct notif_client *self, char *buf,
+ struct notif_client *self, const char *buf,
struct notif_event *event);
/* Check this notification client can get pending events in
@@ -106,15 +106,16 @@ struct remote_notif_state
struct notif_event *pending_event[REMOTE_NOTIF_LAST];
};
-void remote_notif_ack (remote_target *remote, notif_client *nc, char *buf);
+void remote_notif_ack (remote_target *remote, notif_client *nc,
+ const char *buf);
struct notif_event *remote_notif_parse (remote_target *remote,
notif_client *nc,
- char *buf);
+ const char *buf);
void notif_event_xfree (struct notif_event *event);
void handle_notification (struct remote_notif_state *notif_state,
- char *buf);
+ const char *buf);
void remote_notif_process (struct remote_notif_state *state,
struct notif_client *except);