diff options
Diffstat (limited to 'bin')
-rw-r--r-- | bin/ps/ps.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/bin/ps/ps.c b/bin/ps/ps.c index 2488ef6..466a8e9 100644 --- a/bin/ps/ps.c +++ b/bin/ps/ps.c @@ -497,7 +497,7 @@ main(int argc, char *argv[]) */ nentries = -1; kp = kvm_getprocs(kd, what, flag, &nentries); - if ((kp == 0 && nentries != 0) || nentries < 0) + if ((kp == 0 && nentries > 0) || (kp != 0 && nentries < 0)) errx(1, "%s", kvm_geterr(kd)); nkept = 0; if (nentries > 0) { |