aboutsummaryrefslogtreecommitdiff
path: root/gdb/cli/cli-setshow.c
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/cli/cli-setshow.c')
-rw-r--r--gdb/cli/cli-setshow.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/gdb/cli/cli-setshow.c b/gdb/cli/cli-setshow.c
index 206a55d..851f042 100644
--- a/gdb/cli/cli-setshow.c
+++ b/gdb/cli/cli-setshow.c
@@ -177,14 +177,14 @@ do_setshow_command (char *arg, int from_tty, struct cmd_list_element *c)
arg = "";
if (*(char **) c->var != NULL)
xfree (*(char **) c->var);
- *(char **) c->var = savestring (arg, strlen (arg));
+ *(char **) c->var = xstrdup (arg);
break;
case var_optional_filename:
if (arg == NULL)
arg = "";
if (*(char **) c->var != NULL)
xfree (*(char **) c->var);
- *(char **) c->var = savestring (arg, strlen (arg));
+ *(char **) c->var = xstrdup (arg);
break;
case var_filename:
if (arg == NULL)