diff options
author | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2014-08-02 11:12:21 -0400 |
---|---|---|
committer | Anthony G. Basile <blueness@gentoo.org> | 2014-08-05 08:38:32 -0400 |
commit | d8808bc08276edf9e27b2b96bcd71fe4ca3a528c (patch) | |
tree | c3e0c4be9e036f8e51076822b80bf344aeefdf6d /src/udev/udev-watch.c | |
parent | ba3e123a228142da43902fda5f63b1cf7cd7d96d (diff) |
Unify parse_argv style
getopt is usually good at printing out a nice error message when
commandline options are invalid. It distinguishes between an unknown
option and a known option with a missing arg. It is better to let it
do its job and not use opterr=0 unless we actually want to suppress
messages. So remove opterr=0 in the few places where it wasn't really
useful.
When an error in options is encountered, we should not print a lengthy
help() and overwhelm the user, when we know precisely what is wrong
with the commandline. In addition, since help() prints to stdout, it
should not be used except when requested with -h or --help.
Also, simplify things here and there.
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
Diffstat (limited to 'src/udev/udev-watch.c')
0 files changed, 0 insertions, 0 deletions