Matt McCutchen's Web Site
/
rsync
/
rsync.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
277d99e
)
Fixed the output of popt errors and changed our one option to be
author
Wayne Davison
<wayned@samba.org>
Sat, 5 Jul 2003 19:21:41 +0000
(19:21 +0000)
committer
Wayne Davison
<wayned@samba.org>
Sat, 5 Jul 2003 19:21:41 +0000
(19:21 +0000)
--iterations (-i).
wildtest.c
patch
|
blob
|
blame
|
history
diff --git
a/wildtest.c
b/wildtest.c
index
c7aa58d
..
c90e405
100644
(file)
--- a/
wildtest.c
+++ b/
wildtest.c
@@
-22,7
+22,7
@@
int output_iterations = 0;
static struct poptOption long_options[] = {
/* longName, shortName, argInfo, argPtr, value, descrip, argDesc */
static struct poptOption long_options[] = {
/* longName, shortName, argInfo, argPtr, value, descrip, argDesc */
- {"
count", 'c
', POPT_ARG_NONE, &output_iterations, 0, 0, 0},
+ {"
iterations", 'i
', POPT_ARG_NONE, &output_iterations, 0, 0, 0},
{0,0,0,0, 0, 0, 0}
};
{0,0,0,0, 0, 0, 0}
};
@@
-66,7
+66,9
@@
main(int argc, char **argv)
while ((opt = poptGetNextOpt(pc)) != -1) {
switch (opt) {
default:
while ((opt = poptGetNextOpt(pc)) != -1) {
switch (opt) {
default:
- fprintf(stderr, "Unknown option: `%c'\n", opt);
+ fprintf(stderr, "%s: %s\n",
+ poptBadOption(pc, POPT_BADOPTION_NOALIAS),
+ poptStrerror(opt));
exit(1);
}
}
exit(1);
}
}