aboutsummaryrefslogtreecommitdiff
path: root/gdb/mi
diff options
context:
space:
mode:
authorTom Tromey <tromey@redhat.com>2011-04-29 18:44:15 +0000
committerTom Tromey <tromey@redhat.com>2011-04-29 18:44:15 +0000
commit38a714bb6f2ead72198b2be9e02b48e140715156 (patch)
tree24097d6abee50ed96120d1c36e8363458795f5b5 /gdb/mi
parenteb73ad13537571163d9fb6818f0931d71dad141a (diff)
downloadgdb-38a714bb6f2ead72198b2be9e02b48e140715156.zip
gdb-38a714bb6f2ead72198b2be9e02b48e140715156.tar.gz
gdb-38a714bb6f2ead72198b2be9e02b48e140715156.tar.bz2
* mi/mi-parse.c (mi_parse): Remove incorrect sizeof.
(mi_parse): Likewise. * breakpoint.c (break_range_command): Use sizeof char*, not char**. (create_breakpoint): Likewise. (parse_breakpoint_sals): Likewise.
Diffstat (limited to 'gdb/mi')
-rw-r--r--gdb/mi/mi-parse.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/gdb/mi/mi-parse.c b/gdb/mi/mi-parse.c
index fcaf151..a46274a 100644
--- a/gdb/mi/mi-parse.c
+++ b/gdb/mi/mi-parse.c
@@ -253,7 +253,7 @@ mi_parse (char *cmd, char **token)
/* Find/skip any token and then extract it. */
for (chp = cmd; *chp >= '0' && *chp <= '9'; chp++)
;
- *token = xmalloc ((chp - cmd + 1) * sizeof (char *));
+ *token = xmalloc (chp - cmd + 1);
memcpy (*token, cmd, (chp - cmd));
(*token)[chp - cmd] = '\0';
@@ -276,7 +276,7 @@ mi_parse (char *cmd, char **token)
for (; *chp && !isspace (*chp); chp++)
;
- parse->command = xmalloc ((chp - tmp + 1) * sizeof (char *));
+ parse->command = xmalloc (chp - tmp + 1);
memcpy (parse->command, tmp, chp - tmp);
parse->command[chp - tmp] = '\0';
}