summaryrefslogtreecommitdiff
path: root/usr.bin/w
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>2005-04-11 07:04:48 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>2005-04-11 07:04:48 +0000
commit97b5b2af9ebc987ea6fbbc9bbe9521faf08f100e (patch)
tree7891275d2564e5cc7a73eecec4cb3484030b5c80 /usr.bin/w
parent4073fe9dcea56411dba8f5771ad7a1c5190a70f5 (diff)
spacing
Diffstat (limited to 'usr.bin/w')
-rw-r--r--usr.bin/w/pr_time.c6
-rw-r--r--usr.bin/w/proc_compare.c6
-rw-r--r--usr.bin/w/w.c18
3 files changed, 15 insertions, 15 deletions
diff --git a/usr.bin/w/pr_time.c b/usr.bin/w/pr_time.c
index 7480638d1e2..274a9df531b 100644
--- a/usr.bin/w/pr_time.c
+++ b/usr.bin/w/pr_time.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pr_time.c,v 1.12 2003/11/26 00:31:27 millert Exp $ */
+/* $OpenBSD: pr_time.c,v 1.13 2005/04/11 07:04:47 deraadt Exp $ */
/*-
* Copyright (c) 1990, 1993, 1994
@@ -33,7 +33,7 @@
#if 0
static char sccsid[] = "@(#)pr_time.c 8.2 (Berkeley) 4/4/94";
#else
-static char *rcsid = "$OpenBSD: pr_time.c,v 1.12 2003/11/26 00:31:27 millert Exp $";
+static char *rcsid = "$OpenBSD: pr_time.c,v 1.13 2005/04/11 07:04:47 deraadt Exp $";
#endif
#endif /* not lint */
@@ -48,7 +48,7 @@ static char *rcsid = "$OpenBSD: pr_time.c,v 1.12 2003/11/26 00:31:27 millert Exp
/*
* pr_attime --
- * Print the time since the user logged in.
+ * Print the time since the user logged in.
*/
void
pr_attime(time_t *started, time_t *now)
diff --git a/usr.bin/w/proc_compare.c b/usr.bin/w/proc_compare.c
index da630aaec3a..a52bc8cdb02 100644
--- a/usr.bin/w/proc_compare.c
+++ b/usr.bin/w/proc_compare.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: proc_compare.c,v 1.9 2004/11/18 15:10:24 markus Exp $ */
+/* $OpenBSD: proc_compare.c,v 1.10 2005/04/11 07:04:47 deraadt Exp $ */
/*-
* Copyright (c) 1990, 1993
@@ -33,7 +33,7 @@
#if 0
static char sccsid[] = "@(#)proc_compare.c 8.2 (Berkeley) 9/23/93";
#else
-static char *rcsid = "$OpenBSD: proc_compare.c,v 1.9 2004/11/18 15:10:24 markus Exp $";
+static char *rcsid = "$OpenBSD: proc_compare.c,v 1.10 2005/04/11 07:04:47 deraadt Exp $";
#endif
#endif /* not lint */
@@ -93,7 +93,7 @@ proc_compare(const struct kinfo_proc2 *p1, const struct kinfo_proc2 *p2)
return (p2->p_pid > p1->p_pid); /* tie - return highest pid */
}
/*
- * weed out zombies
+ * weed out zombies
*/
switch (TESTAB(p1->p_stat == SZOMB, p2->p_stat == SZOMB)) {
case ONLYA:
diff --git a/usr.bin/w/w.c b/usr.bin/w/w.c
index f9c8169b532..817a97f62e1 100644
--- a/usr.bin/w/w.c
+++ b/usr.bin/w/w.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: w.c,v 1.43 2004/09/14 22:24:24 deraadt Exp $ */
+/* $OpenBSD: w.c,v 1.44 2005/04/11 07:04:47 deraadt Exp $ */
/*-
* Copyright (c) 1980, 1991, 1993, 1994
@@ -39,7 +39,7 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)w.c 8.4 (Berkeley) 4/16/94";
#else
-static char *rcsid = "$OpenBSD: w.c,v 1.43 2004/09/14 22:24:24 deraadt Exp $";
+static char *rcsid = "$OpenBSD: w.c,v 1.44 2005/04/11 07:04:47 deraadt Exp $";
#endif
#endif /* not lint */
@@ -264,18 +264,18 @@ main(int argc, char *argv[])
}
}
if ((ioctl(STDOUT_FILENO, TIOCGWINSZ, &ws) == -1 &&
- ioctl(STDERR_FILENO, TIOCGWINSZ, &ws) == -1 &&
- ioctl(STDIN_FILENO, TIOCGWINSZ, &ws) == -1) || ws.ws_col == 0)
- ttywidth = 79;
- else
- ttywidth = ws.ws_col - 1;
+ ioctl(STDERR_FILENO, TIOCGWINSZ, &ws) == -1 &&
+ ioctl(STDIN_FILENO, TIOCGWINSZ, &ws) == -1) || ws.ws_col == 0)
+ ttywidth = 79;
+ else
+ ttywidth = ws.ws_col - 1;
argwidth = ttywidth - WUSED;
if (argwidth < 4)
argwidth = 8;
/* sort by idle time */
if (sortidle && ehead != NULL) {
struct entry *from = ehead, *save;
-
+
ehead = NULL;
while (from != NULL) {
for (nextp = &ehead;
@@ -288,7 +288,7 @@ main(int argc, char *argv[])
*nextp = save;
}
}
-
+
if (!nflag) {
if (gethostname(domain, sizeof(domain)) < 0 ||
(p = strchr(domain, '.')) == 0)