Handle `-f arg' correctly.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@2579 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
@@ -275,10 +275,10 @@ getarg(struct getargs *args, size_t num_args,
|
|||||||
if(sscanf(optarg, "%d", &tmp) != 1)
|
if(sscanf(optarg, "%d", &tmp) != 1)
|
||||||
return ARG_ERR_BAD_ARG;
|
return ARG_ERR_BAD_ARG;
|
||||||
*(int*)args[k].value = tmp;
|
*(int*)args[k].value = tmp;
|
||||||
break;
|
goto out;
|
||||||
}else if(args[k].type == arg_string){
|
}else if(args[k].type == arg_string){
|
||||||
*(char**)args[k].value = optarg;
|
*(char**)args[k].value = optarg;
|
||||||
break;
|
goto out;
|
||||||
}
|
}
|
||||||
return ARG_ERR_BAD_ARG;
|
return ARG_ERR_BAD_ARG;
|
||||||
}
|
}
|
||||||
@@ -287,6 +287,7 @@ getarg(struct getargs *args, size_t num_args,
|
|||||||
if (k == num_args)
|
if (k == num_args)
|
||||||
return ARG_ERR_NO_MATCH;
|
return ARG_ERR_NO_MATCH;
|
||||||
}
|
}
|
||||||
|
out:
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
*optind = i;
|
*optind = i;
|
||||||
|
Reference in New Issue
Block a user