Commit c21306eb authored by Alan Coopersmith's avatar Alan Coopersmith

Print which option was in error along with usage message

Signed-off-by: Alan Coopersmith's avatarAlan Coopersmith <alan.coopersmith@oracle.com>
parent 3c312339
......@@ -407,6 +407,8 @@ main (int argc, char *argv[])
i++;
if (argv[i] == NULL)
{
fprintf (stderr, "%s: %s requires an argument\n",
argv[0], argv[i-1]);
usage (argv[0]);
return 1;
}
......@@ -420,6 +422,7 @@ main (int argc, char *argv[])
out = argv[i];
else
{
fprintf (stderr, "%s: unexpected argument '%s'\n", argv[0], argv[i]);
usage (argv[0]);
return 1;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment