diff options
author | Camiel Dobbelaar <camield@cvs.openbsd.org> | 2001-09-03 18:08:11 +0000 |
---|---|---|
committer | Camiel Dobbelaar <camield@cvs.openbsd.org> | 2001-09-03 18:08:11 +0000 |
commit | c9b19c1ab793e5064eea62d43047900557a7d1f1 (patch) | |
tree | 5550281f1a284d542b05d9ddf297315a82f4dd67 | |
parent | c2731667f3c64e5556f87caf10ec68d7ccbceb14 (diff) |
don't print zero values on processes line
ok millert@
-rw-r--r-- | usr.bin/top/display.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/usr.bin/top/display.c b/usr.bin/top/display.c index 7b4efd4da46..ea6feb368db 100644 --- a/usr.bin/top/display.c +++ b/usr.bin/top/display.c @@ -1,4 +1,4 @@ -/* $OpenBSD: display.c,v 1.6 2001/08/24 20:16:35 art Exp $ */ +/* $OpenBSD: display.c,v 1.7 2001/09/03 18:08:10 camield Exp $ */ /* * Top users/processes display for Unix @@ -999,7 +999,7 @@ register char **names; /* skip over the K, since it was included by format_k */ p = strecpy(p, thisname+1); } - else + else if (num > 0) { p = strecpy(p, itoa(num)); p = strecpy(p, thisname); @@ -1007,7 +1007,7 @@ register char **names; } /* ignore negative numbers, but display corresponding string */ - else if (num < 0) + else { p = strecpy(p, thisname); } |