This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
[PATCH 03/13] constify inf_child_open_target
- From: Tom Tromey <tromey at redhat dot com>
- To: gdb-patches at sourceware dot org
- Cc: Tom Tromey <tromey at redhat dot com>
- Date: Tue, 22 Jul 2014 12:55:09 -0600
- Subject: [PATCH 03/13] constify inf_child_open_target
- Authentication-results: sourceware.org; auth=none
- References: <1406055319-26380-1-git-send-email-tromey at redhat dot com>
This constifies an argument to inf_child_open_target.
2014-07-22 Tom Tromey <tromey@redhat.com>
* inf-child.c (inf_child_open_target): Make "arg" const.
* inf-child.h (inf_child_open_target): Update.
---
gdb/ChangeLog | 5 +++++
gdb/inf-child.c | 3 ++-
gdb/inf-child.h | 2 +-
3 files changed, 8 insertions(+), 2 deletions(-)
diff --git a/gdb/inf-child.c b/gdb/inf-child.c
index 897e635..883ed77 100644
--- a/gdb/inf-child.c
+++ b/gdb/inf-child.c
@@ -122,7 +122,8 @@ static int inf_child_explicitly_opened;
/* See inf-child.h. */
void
-inf_child_open_target (struct target_ops *target, char *arg, int from_tty)
+inf_child_open_target (struct target_ops *target, const char *arg,
+ int from_tty)
{
target_preopen (from_tty);
push_target (target);
diff --git a/gdb/inf-child.h b/gdb/inf-child.h
index b2692ca..163cab6 100644
--- a/gdb/inf-child.h
+++ b/gdb/inf-child.h
@@ -34,7 +34,7 @@ extern void store_waitstatus (struct target_waitstatus *, int);
the target, in case it need to override to_open. */
extern void inf_child_open_target (struct target_ops *target,
- char *arg, int from_tty);
+ const char *arg, int from_tty);
/* To be called by the native target's to_mourn_inferior routine. */
--
1.9.3