summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjbj <jbj>2006-08-05 08:34:48 +0000
committerjbj <jbj>2006-08-05 08:34:48 +0000
commit84ccdd28cdd80d21d0ed84590705d75154f59a23 (patch)
treef1236111ce46620cce0f35b5a693f21ba3ad2a24
parent3d6acf30002f661cc9b2c346691db44beff5c824 (diff)
downloadlibpopt-84ccdd28cdd80d21d0ed84590705d75154f59a23.tar.gz
fix: print short options only once (#200508).
-rw-r--r--popthelp.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/popthelp.c b/popthelp.c
index 0f62d2f..82bf6f8 100644
--- a/popthelp.c
+++ b/popthelp.c
@@ -775,7 +775,7 @@ static int showShortOptions(const struct poptOption * opt, FILE * fp,
/*@=boundswrite@*/
/* On return to top level, print the short options, return print length. */
- if (s == str && *s != '\0') {
+ if (s != str && *s != '\0') {
fprintf(fp, " [-%s]", s);
len = strlen(s) + sizeof(" [-]")-1;
}