diff options
author | Werner Koch <[email protected]> | 1998-02-11 23:22:09 +0000 |
---|---|---|
committer | Werner Koch <[email protected]> | 1998-02-11 23:22:09 +0000 |
commit | bc5789665ae8c9f8fc3d02841cd6c9ade447a12a (patch) | |
tree | a98aa9fdf58eaffecb38ce481606ee8536280fc8 /util/argparse.c | |
parent | a couple of changes; but some parts are now broken (diff) | |
download | gnupg-bc5789665ae8c9f8fc3d02841cd6c9ade447a12a.tar.gz gnupg-bc5789665ae8c9f8fc3d02841cd6c9ade447a12a.zip |
bug fixes
Diffstat (limited to 'util/argparse.c')
-rw-r--r-- | util/argparse.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/util/argparse.c b/util/argparse.c index 795e87648..0c8ad8f0b 100644 --- a/util/argparse.c +++ b/util/argparse.c @@ -221,10 +221,10 @@ optfile_parse( FILE *fp, const char *filename, unsigned *lineno, arg->r_opt = -arg->r_opt; if( !opts[index].short_opt ) arg->r_opt = -2; /* unknown option */ - else if( (opts[index].flags & 8) ) /* no optional argument */ - arg->r_type = 0; /* okay */ - else /* no required argument */ + else if( (opts[index].flags & 8) ) /* no argument */ arg->r_opt = -3; /* error */ + else /* no or optiona argument */ + arg->r_type = 0; /* okay */ break; } else if( state == 3 ) { /* no argument found */ |