+2011-04-29 Tom Tromey <tromey@redhat.com>
+
+ * 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.
+
2011-04-29 Pedro Alves <pedro@codesourcery.com>
* linux-nat.c (linux_child_remove_fork_catchpoint)
}
/* For any SAL that didn't have a canonical string, fill one in. */
if (sals->nelts > 0 && canonical->canonical == NULL)
- canonical->canonical = xcalloc (sals->nelts, sizeof (char **));
+ canonical->canonical = xcalloc (sals->nelts, sizeof (char *));
if (addr_start != (*address))
{
int i;
sals = decode_static_tracepoint_spec (&arg);
copy_arg = savestring (addr_start, arg - addr_start);
- canonical.canonical = xcalloc (sals.nelts, sizeof (char **));
+ canonical.canonical = xcalloc (sals.nelts, sizeof (char *));
for (i = 0; i < sals.nelts; i++)
canonical.canonical[i] = xstrdup (copy_arg);
goto done;
/* canonical_end can be NULL if it was of the form "*0xdeadbeef". */
if (canonical_end.canonical == NULL)
- canonical_end.canonical = xcalloc (1, sizeof (char **));
+ canonical_end.canonical = xcalloc (1, sizeof (char *));
/* Add the string if not present. */
if (arg_start != arg && canonical_end.canonical[0] == NULL)
canonical_end.canonical[0] = savestring (arg_start, arg - arg_start);
/* 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';
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';
}