mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-12 22:03:02 +00:00
main: fix error message for missing argument
* src/getargs.c (getargs): Don't display any argv other that argv[0] when reporting a missing argument. * tests/bison.in: Neutralize path differences in stderr. * tests/input.at (Invalid number of arguments): New.
This commit is contained in:
@@ -724,7 +724,7 @@ getargs (int argc, char *argv[])
|
||||
if (argc - optind != 1)
|
||||
{
|
||||
if (argc - optind < 1)
|
||||
error (0, 0, _("%s: missing operand"), quotearg_colon (argv[argc - 1]));
|
||||
error (0, 0, _("missing operand"));
|
||||
else
|
||||
error (0, 0, _("extra operand %s"), quote (argv[optind + 1]));
|
||||
usage (EXIT_FAILURE);
|
||||
|
||||
Reference in New Issue
Block a user