summaryrefslogtreecommitdiff
path: root/bin/ps
diff options
context:
space:
mode:
authorMike Pechkin <mpech@cvs.openbsd.org>2001-09-06 13:29:09 +0000
committerMike Pechkin <mpech@cvs.openbsd.org>2001-09-06 13:29:09 +0000
commite9adfbcaf16f3287027630e6f8926cbf5195af9f (patch)
treeb20ad65ef5726147335786dc24cc1d1a00d5c7f3 /bin/ps
parent99d09c2c5ce8a0c313c2a485a4a6a8ed24e805c5 (diff)
o) __progname aria;
millert@ ok.
Diffstat (limited to 'bin/ps')
-rw-r--r--bin/ps/ps.c16
1 files changed, 9 insertions, 7 deletions
diff --git a/bin/ps/ps.c b/bin/ps/ps.c
index eebfa04e8cd..5d8b689e28b 100644
--- a/bin/ps/ps.c
+++ b/bin/ps/ps.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ps.c,v 1.21 2001/06/03 04:48:15 angelos Exp $ */
+/* $OpenBSD: ps.c,v 1.22 2001/09/06 13:29:08 mpech Exp $ */
/* $NetBSD: ps.c,v 1.15 1995/05/18 20:33:25 mycroft Exp $ */
/*-
@@ -44,7 +44,7 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)ps.c 8.4 (Berkeley) 4/2/94";
#else
-static char rcsid[] = "$OpenBSD: ps.c,v 1.21 2001/06/03 04:48:15 angelos Exp $";
+static char rcsid[] = "$OpenBSD: ps.c,v 1.22 2001/09/06 13:29:08 mpech Exp $";
#endif
#endif /* not lint */
@@ -74,6 +74,8 @@ static char rcsid[] = "$OpenBSD: ps.c,v 1.21 2001/06/03 04:48:15 angelos Exp $";
#include "ps.h"
+extern char *__progname;
+
KINFO *kinfo;
struct varent *vhead, *vtail;
@@ -519,11 +521,11 @@ kludge_oldps_options(s)
static void
usage()
{
-
(void)fprintf(stderr,
- "usage:\t%s\n\t %s\n\t%s\n",
- "ps [-][aChjlmrSTuvwx] [-O|o fmt] [-p pid] [-t tty] [-U user]",
- "[-M core] [-N system] [-W swap]",
- "ps [-L]");
+ "usage: %s [-][aChjlmrSTuvwx] [-O|o fmt] [-p pid] [-t tty] [-U user]\n",
+ __progname);
+ (void)fprintf(stderr,
+ "%-*s[-M core] [-N system] [-W swap]\n", strlen(__progname) + 8, "");
+ (void)fprintf(stderr, " %s [-L]\n", __progname);
exit(1);
}