From 652303d9079f34d7484c4b9410582885dbbd3509 Mon Sep 17 00:00:00 2001 From: Jim Meyering Date: Thu, 16 Aug 2001 05:47:48 +0000 Subject: [PATCH] (main): When there are too many non-option arguments, include the first offending argument in the diagnostic. Suggestion from Karl Berry. --- src/date.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/date.c b/src/date.c index ac38f87..64aeed4 100644 --- a/src/date.c +++ b/src/date.c @@ -341,7 +341,8 @@ main (int argc, char **argv) if (n_args > 1) { - error (0, 0, _("too many non-option arguments")); + error (0, 0, _("too many non-option arguments: %s%s"), + argv[optind + 1], n_args == 2 ? "" : " ..."); usage (1); } -- 2.7.4