mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-06-05 15:17:13 +08:00
Make check_for_argument skip whitespace after arg itself
Basically every caller of check_for_argument needs to skip space after the argument. This patch makes check_for_argument do it itself. Suggested by Philippe Waroquiers. gdb/ChangeLog: 2019-06-13 Pedro Alves <palves@redhat.com> * ax-gdb.c (agent_command_1): Remove skip_spaces call. * breakpoint.c (watch_maybe_just_location): Remove skip_spaces call. * cli/cli-cmds.c (apropos_command): Remove skip_spaces call. * cli/cli-utils.c (extract_info_print_args): Remove skip_spaces calls. (check_for_argument): Skip spaces after argument.
This commit is contained in:
@ -1381,9 +1381,6 @@ apropos_command (const char *arg, int from_tty)
|
||||
{
|
||||
bool verbose = arg && check_for_argument (&arg, "-v", 2);
|
||||
|
||||
if (verbose)
|
||||
arg = skip_spaces (arg);
|
||||
|
||||
if (arg == NULL || *arg == '\0')
|
||||
error (_("REGEXP string is empty"));
|
||||
|
||||
|
Reference in New Issue
Block a user