+2010-12-09 Marc Khouzam <marc.khouzam@ericsson.com>
+
+ * mi/mi-parse.c (mi_parse): Wrong error message.
+
2010-12-09 Doug Evans <dje@google.com>
* symfile.h (quick_symbol_functions): Clarify usage of
to CLI. */
for (;;)
{
- char *start = chp;
+ const char *option;
size_t as = sizeof ("--all ") - 1;
size_t tgs = sizeof ("--thread-group ") - 1;
size_t ts = sizeof ("--thread ") - 1;
}
if (strncmp (chp, "--thread-group ", tgs) == 0)
{
+ option = "--thread-group";
if (parse->thread_group != -1)
error (_("Duplicate '--thread-group' option"));
chp += tgs;
}
else if (strncmp (chp, "--thread ", ts) == 0)
{
+ option = "--thread";
if (parse->thread != -1)
error (_("Duplicate '--thread' option"));
chp += ts;
}
else if (strncmp (chp, "--frame ", fs) == 0)
{
+ option = "--frame";
if (parse->frame != -1)
error (_("Duplicate '--frame' option"));
chp += fs;
break;
if (*chp != '\0' && !isspace (*chp))
- error (_("Invalid value for the '%s' option"),
- start[2] == 't' ? "--thread" : "--frame");
+ error (_("Invalid value for the '%s' option"), option);
while (isspace (*chp))
chp++;
}