From 8d62d06e90311aab0fcc0e3574e76919c43dcc94 Mon Sep 17 00:00:00 2001 From: Peter Valchev Date: Thu, 24 May 2001 03:04:36 +0000 Subject: - Add a main() prototype. - Use __progname in usage(). millert@ ok --- usr.bin/nice/nice.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'usr.bin') diff --git a/usr.bin/nice/nice.c b/usr.bin/nice/nice.c index c119b88a32c..c6a691be491 100644 --- a/usr.bin/nice/nice.c +++ b/usr.bin/nice/nice.c @@ -1,4 +1,4 @@ -/* $OpenBSD: nice.c,v 1.3 2000/11/07 09:04:21 kevlo Exp $ */ +/* $OpenBSD: nice.c,v 1.4 2001/05/24 03:04:35 pvalchev Exp $ */ /* $NetBSD: nice.c,v 1.9 1995/08/31 23:30:58 jtc Exp $ */ /* @@ -44,7 +44,7 @@ char copyright[] = #if 0 static char sccsid[] = "@(#)nice.c 5.4 (Berkeley) 6/1/90"; #endif -static char rcsid[] = "$OpenBSD: nice.c,v 1.3 2000/11/07 09:04:21 kevlo Exp $"; +static char rcsid[] = "$OpenBSD: nice.c,v 1.4 2001/05/24 03:04:35 pvalchev Exp $"; #endif /* not lint */ #include @@ -61,6 +61,7 @@ static char rcsid[] = "$OpenBSD: nice.c,v 1.3 2000/11/07 09:04:21 kevlo Exp $"; #define DEFNICE 10 +int main __P((int, char **)); static void usage __P((void)); int @@ -114,8 +115,8 @@ main(argc, argv) static void usage() { - (void)fprintf(stderr, - "usage: nice [ -n increment ] utility [ argument ...]\n"); - + extern char *__progname; + fprintf(stderr, "usage: %s [ -n increment ] utility [ argument ...]\n", + __progname); exit(1); } -- cgit v1.2.3