mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-08-06 06:45:56 +08:00
* tracepoint.c (trace_actions_command): Update.
* thread.c (thread_apply_command): Update. * reverse.c (delete_bookmark_command): Update. (bookmarks_info): Update. * printcmd.c (undisplay_command): Update. * memattr.c (mem_enable_command): Update. (mem_disable_command): Update. (mem_delete_command): Update. * inferior.c (detach_inferior_command): Update. (kill_inferior_command): Update. (remove_inferior_command): Update. * cli/cli-utils.h (struct get_number_or_range_state): New. (init_number_or_range): Declare. (get_number_or_range): Update. * cli/cli-utils.c (init_number_or_range): New function. (get_number_or_range): Change 'pp' parameter to 'state'. Remove static variables. (number_is_in_list): Update. * breakpoint.h (get_tracepoint_by_number): Update. * breakpoint.c (map_breakpoint_numbers): Update for change to get_number_or_range. (find_location_by_number): Use get_number, not get_number_or_range. (trace_pass_set_count): New function. (trace_pass_command): Update for change to get_number_or_range. Rework loop logic. (get_tracepoint_by_number): Remove 'multi_p' parameter; add 'state' parameter.
This commit is contained in:
@ -222,6 +222,7 @@ delete_bookmark_command (char *args, int from_tty)
|
||||
{
|
||||
struct bookmark *b;
|
||||
int num;
|
||||
struct get_number_or_range_state state;
|
||||
|
||||
if (bookmark_chain == NULL)
|
||||
{
|
||||
@ -237,9 +238,10 @@ delete_bookmark_command (char *args, int from_tty)
|
||||
return;
|
||||
}
|
||||
|
||||
while (args != NULL && *args != '\0')
|
||||
init_number_or_range (&state, args);
|
||||
while (!state.finished)
|
||||
{
|
||||
num = get_number_or_range (&args);
|
||||
num = get_number_or_range (&state);
|
||||
if (!delete_one_bookmark (num))
|
||||
/* Not found. */
|
||||
warning (_("No bookmark #%d."), num);
|
||||
@ -328,11 +330,16 @@ bookmarks_info (char *args, int from_tty)
|
||||
else if (args == NULL || *args == '\0')
|
||||
bookmark_1 (-1);
|
||||
else
|
||||
while (args != NULL && *args != '\0')
|
||||
{
|
||||
bnum = get_number_or_range (&args);
|
||||
bookmark_1 (bnum);
|
||||
}
|
||||
{
|
||||
struct get_number_or_range_state state;
|
||||
|
||||
init_number_or_range (&state, args);
|
||||
while (!state.finished)
|
||||
{
|
||||
bnum = get_number_or_range (&state);
|
||||
bookmark_1 (bnum);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user