This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
[PATCH 3/7] fix up parse_cli_boolean_value after rebase
- From: Tom Tromey <tromey at redhat dot com>
- To: gdb-patches at sourceware dot org
- Cc: Tom Tromey <tromey at redhat dot com>
- Date: Wed, 11 Jun 2014 12:53:13 -0600
- Subject: [PATCH 3/7] fix up parse_cli_boolean_value after rebase
- Authentication-results: sourceware.org; auth=none
- References: <1402512797-6082-1-git-send-email-tromey at redhat dot com>
This changes a parameter of parse_cli_boolean_value to be const.
2014-06-11 Tom Tromey <tromey@redhat.com>
* cli/cli-setshow.h (parse_cli_boolean_value): Update.
* cli/cli-setshow.c (parse_cli_boolean_value): Make "arg" const.
---
gdb/ChangeLog | 5 +++++
gdb/cli/cli-setshow.c | 2 +-
gdb/cli/cli-setshow.h | 2 +-
3 files changed, 7 insertions(+), 2 deletions(-)
diff --git a/gdb/cli/cli-setshow.c b/gdb/cli/cli-setshow.c
index 75f1526..d14d361 100644
--- a/gdb/cli/cli-setshow.c
+++ b/gdb/cli/cli-setshow.c
@@ -76,7 +76,7 @@ parse_auto_binary_operation (const char *arg)
/* See cli-setshow.h. */
int
-parse_cli_boolean_value (char *arg)
+parse_cli_boolean_value (const char *arg)
{
int length;
diff --git a/gdb/cli/cli-setshow.h b/gdb/cli/cli-setshow.h
index a41a66d..a68d610 100644
--- a/gdb/cli/cli-setshow.h
+++ b/gdb/cli/cli-setshow.h
@@ -21,7 +21,7 @@ struct cmd_list_element;
/* Parse ARG, an option to a boolean variable.
Returns 1 for true, 0 for false, and -1 if invalid. */
-extern int parse_cli_boolean_value (char *arg);
+extern int parse_cli_boolean_value (const char *arg);
extern void do_set_command (char *arg, int from_tty,
struct cmd_list_element *c);
--
1.9.3