Merge r362 from libarchive.googlecode.com: Minor fix to

custom argument parser.
This commit is contained in:
Tim Kientzle 2009-03-05 00:41:02 +00:00
parent 32baf20434
commit 24b4dd3387
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=189384

View File

@ -975,9 +975,10 @@ int main(int argc, char **argv)
*/
++argv; --argc;/* Skip program name */
while (*argv != NULL) {
if (**argv != '-')
break;
p = *argv++;
if (*p++ != '-')
usage(progname);
++p; /* Skip '-' */
while (*p != '\0') {
option = *p++;
option_arg = NULL;