diff options
author | 2015-09-23 22:01:30 +0000 | |
---|---|---|
committer | 2015-09-23 22:01:30 +0000 | |
commit | a984fe273c651f3fbdbca8311ddee4529ef08545 (patch) | |
tree | f6baa314dc7ffc047473c71f3290379dc550152f | |
parent | typos (diff) | |
download | wireguard-openbsd-a984fe273c651f3fbdbca8311ddee4529ef08545.tar.xz wireguard-openbsd-a984fe273c651f3fbdbca8311ddee4529ef08545.zip |
No need for err.h, avoid excess fputs() calls and return from main
instead of calling exit(). From Michael Reed.
-rw-r--r-- | usr.bin/arch/arch.c | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/usr.bin/arch/arch.c b/usr.bin/arch/arch.c index 99d890c4a32..d4e90eb85d5 100644 --- a/usr.bin/arch/arch.c +++ b/usr.bin/arch/arch.c @@ -25,7 +25,6 @@ #include <sys/param.h> /* MACHINE MACHINE_ARCH */ -#include <err.h> #include <locale.h> #include <stdio.h> #include <stdlib.h> @@ -73,13 +72,10 @@ main(int argc, char *argv[]) usage(); /* NOTREACHED */ } - if (!short_form) { - fputs("OpenBSD", stdout); - fputc('.', stdout); - } - fputs(arch, stdout); - fputc('\n', stdout); - exit(0); + if (!short_form) + fputs("OpenBSD.", stdout); + puts(arch); + return 0; } static void |