aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPřemysl Eric Janouch <p@janouch.name>2020-10-13 21:27:46 +0200
committerPřemysl Eric Janouch <p@janouch.name>2020-10-13 21:27:46 +0200
commit69101eb1554ad2fca6de30cdbaccac076210d7e3 (patch)
tree543a61645465565b4e6f8b09dafc0518e07ee1aa
parent9d14562f7e81441b244dc9b2e69004ad285a5ff2 (diff)
downloadliberty-69101eb1554ad2fca6de30cdbaccac076210d7e3.tar.gz
liberty-69101eb1554ad2fca6de30cdbaccac076210d7e3.tar.xz
liberty-69101eb1554ad2fca6de30cdbaccac076210d7e3.zip
Fix optional arguments in --help output
An equals sign is necessary.
-rw-r--r--liberty.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/liberty.c b/liberty.c
index 5e15ee2..3aadc29 100644
--- a/liberty.c
+++ b/liberty.c
@@ -3782,7 +3782,7 @@ opt_handler_usage (const struct opt_handler *self, FILE *stream)
str_append_printf (&row, "--%s", opt->long_name);
if (opt->arg_hint)
str_append_printf (&row, (opt->flags & OPT_OPTIONAL_ARG)
- ? " [%s]" : " %s", opt->arg_hint);
+ ? "[=%s]" : " %s", opt->arg_hint);
// TODO: keep the indent if there are multiple lines
if (row.len + 2 <= OPT_USAGE_ALIGNMENT_COLUMN)