aboutsummaryrefslogtreecommitdiff
path: root/gdb/python
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/python')
-rw-r--r--gdb/python/py-auto-load.c2
-rw-r--r--gdb/python/py-cmd.c8
-rw-r--r--gdb/python/py-param.c2
3 files changed, 7 insertions, 5 deletions
diff --git a/gdb/python/py-auto-load.c b/gdb/python/py-auto-load.c
index a8cb79c..53a8eb5e 100644
--- a/gdb/python/py-auto-load.c
+++ b/gdb/python/py-auto-load.c
@@ -242,7 +242,7 @@ void
gdbpy_initialize_auto_load (void)
{
struct cmd_list_element *cmd;
- char *cmd_name;
+ const char *cmd_name;
add_setshow_boolean_cmd ("python-scripts", class_support,
&auto_load_python_scripts, _("\
diff --git a/gdb/python/py-cmd.c b/gdb/python/py-cmd.c
index 76670ea..161b4bc 100644
--- a/gdb/python/py-cmd.c
+++ b/gdb/python/py-cmd.c
@@ -103,7 +103,7 @@ cmdpy_destroyer (struct cmd_list_element *self, void *context)
/* We allocated the name, doc string, and perhaps the prefix
name. */
- xfree (self->name);
+ xfree ((char *) self->name);
xfree (self->doc);
xfree (self->prefixname);
@@ -207,7 +207,8 @@ cmdpy_function (struct cmd_list_element *command, char *args, int from_tty)
/* Called by gdb for command completion. */
static VEC (char_ptr) *
-cmdpy_completer (struct cmd_list_element *command, char *text, char *word)
+cmdpy_completer (struct cmd_list_element *command,
+ const char *text, const char *word)
{
cmdpy_object *obj = (cmdpy_object *) get_cmd_context (command);
PyObject *textobj, *wordobj, *resultobj = NULL;
@@ -319,7 +320,8 @@ gdbpy_parse_command_name (const char *name,
struct cmd_list_element *elt;
int len = strlen (name);
int i, lastchar;
- char *prefix_text, *prefix_text2;
+ char *prefix_text;
+ const char *prefix_text2;
char *result;
/* Skip trailing whitespace. */
diff --git a/gdb/python/py-param.c b/gdb/python/py-param.c
index 1970714..acb48cd 100644
--- a/gdb/python/py-param.c
+++ b/gdb/python/py-param.c
@@ -470,7 +470,7 @@ add_setshow_generic (int parmclass, enum command_class cmdclass,
struct cmd_list_element **show_list)
{
struct cmd_list_element *param = NULL;
- char *tmp_name = NULL;
+ const char *tmp_name = NULL;
switch (parmclass)
{