aboutsummaryrefslogtreecommitdiff
path: root/gdb/cli/cli-decode.c
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/cli/cli-decode.c')
-rw-r--r--gdb/cli/cli-decode.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/gdb/cli/cli-decode.c b/gdb/cli/cli-decode.c
index e406157..f5b6fc4 100644
--- a/gdb/cli/cli-decode.c
+++ b/gdb/cli/cli-decode.c
@@ -192,8 +192,7 @@ struct cmd_list_element *
add_cmd (const char *name, enum command_class theclass, cmd_cfunc_ftype *fun,
const char *doc, struct cmd_list_element **list)
{
- struct cmd_list_element *c
- = (struct cmd_list_element *) xmalloc (sizeof (struct cmd_list_element));
+ struct cmd_list_element *c = XNEW (struct cmd_list_element);
struct cmd_list_element *p, *iter;
/* Turn each alias of the old command into an alias of the new