summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexander von Gernler <grunk@cvs.openbsd.org>2006-05-17 13:31:23 +0000
committerAlexander von Gernler <grunk@cvs.openbsd.org>2006-05-17 13:31:23 +0000
commitab5e90fac93b1d59fb80962b7661d580eb739843 (patch)
tree91a1c19e7c129f0a12f0b19aff12588234cf6832
parent69b8aac01676aa3c5ce992be4de80407fd980741 (diff)
remove useless case that is handled by default anyway
zap trailing blanks ok otto@
-rw-r--r--usr.bin/time/time.c17
1 files changed, 8 insertions, 9 deletions
diff --git a/usr.bin/time/time.c b/usr.bin/time/time.c
index d4067da629b..aa60c59330e 100644
--- a/usr.bin/time/time.c
+++ b/usr.bin/time/time.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: time.c,v 1.15 2003/06/10 22:20:53 deraadt Exp $ */
+/* $OpenBSD: time.c,v 1.16 2006/05/17 13:31:22 grunk Exp $ */
/* $NetBSD: time.c,v 1.7 1995/06/27 00:34:00 jtc Exp $ */
/*
@@ -40,7 +40,7 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)time.c 8.1 (Berkeley) 6/6/93";
#endif
-static char rcsid[] = "$OpenBSD: time.c,v 1.15 2003/06/10 22:20:53 deraadt Exp $";
+static char rcsid[] = "$OpenBSD: time.c,v 1.16 2006/05/17 13:31:22 grunk Exp $";
#endif /* not lint */
#include <sys/param.h>
@@ -79,7 +79,6 @@ main(int argc, char *argv[])
case 'p':
portableflag = 1;
break;
- case '?':
default:
usage();
/* NOTREACHED */
@@ -88,8 +87,8 @@ main(int argc, char *argv[])
argc -= optind;
argv += optind;
-
- if (argc < 1)
+
+ if (argc < 1)
usage();
gettimeofday(&before, (struct timezone *)NULL);
@@ -118,7 +117,7 @@ main(int argc, char *argv[])
timersub(&after, &before, &after);
if (portableflag) {
- fprintf(stderr, "real %9ld.%02ld\n",
+ fprintf(stderr, "real %9ld.%02ld\n",
after.tv_sec, after.tv_usec/10000);
fprintf(stderr, "user %9ld.%02ld\n",
ru.ru_utime.tv_sec, ru.ru_utime.tv_usec/10000);
@@ -126,7 +125,7 @@ main(int argc, char *argv[])
ru.ru_stime.tv_sec, ru.ru_stime.tv_usec/10000);
} else {
- fprintf(stderr, "%9ld.%02ld real ",
+ fprintf(stderr, "%9ld.%02ld real ",
after.tv_sec, after.tv_usec/10000);
fprintf(stderr, "%9ld.%02ld user ",
ru.ru_utime.tv_sec, ru.ru_utime.tv_usec/10000);
@@ -191,10 +190,10 @@ main(int argc, char *argv[])
exit(WIFEXITED(status) ? WEXITSTATUS(status) : EXIT_FAILURE);
}
-__dead void
+__dead void
usage(void)
{
- extern char *__progname;
+ extern char *__progname;
(void)fprintf(stderr, "usage: %s [-lp] command\n", __progname);
exit(1);