we weren't quite careful enough about testing for a single -
authorewt <devnull@localhost>
Wed, 7 Apr 1999 06:20:13 +0000 (06:20 +0000)
committerewt <devnull@localhost>
Wed, 7 Apr 1999 06:20:13 +0000 (06:20 +0000)
CVS patchset: 2964
CVS date: 1999/04/07 06:20:13

popt/popt.c

index 4549955..bfcc005 100644 (file)
@@ -257,7 +257,7 @@ static const struct poptOption * findOption(const struct poptOption * table,
     const struct poptOption * cb = NULL;
 
     /* This happens when a single - is given */
-    if (singleDash && !shortName)
+    if (singleDash && !shortName && !*longName)
        shortName = '-';
 
     while (opt->longName || opt->shortName || opt->arg) {