X-Git-Url: https://iankelling.org/git/?a=blobdiff_plain;f=evhz.c;h=1588024ba06b69b4daf35de3805f33592da56139;hb=85054bc738cee1608737a9d445b990b15b109cf1;hp=c4dd389763c5490748809a03db2d8b89a2494258;hpb=95940a911c7bb9bf1c678b58e0a68c2e8c101410;p=evhz diff --git a/evhz.c b/evhz.c index c4dd389..1588024 100644 --- a/evhz.c +++ b/evhz.c @@ -28,22 +28,24 @@ int main(int argc, char *argv[]) { int optch; int i; event_t events[EVENTS]; - int verbose = 0; + int verbose = 1; - while((optch = getopt(argc, argv, "hv")) != -1) { + while((optch = getopt(argc, argv, "hn")) != -1) { switch(optch) { case('h'): - printf("Usage: %s [-v|-h]\n", argv[0]); + printf("Usage: %s [-n|-h]\n", argv[0]); + printf("-n nonverbose\n"); + printf("-h help\n"); return 0; break; - case('v'): - verbose = 1; + case('n'): + verbose = 0; break; } } if(geteuid() != 0) { - printf("%s must be used as superuser", argv[0]); + printf("%s must be used as superuser\n", argv[0]); return 1; }