summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libshouldbeinlibc/argp-parse.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/libshouldbeinlibc/argp-parse.c b/libshouldbeinlibc/argp-parse.c
index 8ec7f223..3f9e3e8c 100644
--- a/libshouldbeinlibc/argp-parse.c
+++ b/libshouldbeinlibc/argp-parse.c
@@ -623,7 +623,8 @@ argp_parse (const struct argp *argp, int argc, char **argv, unsigned flags,
if (err)
{
/* Maybe print an error message. */
- argp_state_help (&state, stderr, ARGP_HELP_STD_ERR);
+ if (err == EBADKEY)
+ argp_state_help (&state, stderr, ARGP_HELP_STD_ERR);
/* Since we didn't exit, give each parser an error indication. */
for (group = groups; group < egroup; group++)