diff options
author | Alan Coopersmith <alan.coopersmith@oracle.com> | 2013-11-26 22:22:30 -0800 |
---|---|---|
committer | Alan Coopersmith <alan.coopersmith@oracle.com> | 2013-11-26 22:22:45 -0800 |
commit | c21306ebf8cfa780d3d4fd31a41d1c7cac2e8dbb (patch) | |
tree | 8ee6acb5c55ff89cac627459587db1106177995c | |
parent | 3c31233990f8c91b4f54b4ba7d4cd02f67c7812e (diff) |
Print which option was in error along with usage message
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
-rw-r--r-- | xcursorgen.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/xcursorgen.c b/xcursorgen.c index 2dda7ad..f292f19 100644 --- a/xcursorgen.c +++ b/xcursorgen.c @@ -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; } |