From: Eitan Adler Date: Sun, 21 Jan 2018 09:01:26 +0000 (-0800) Subject: limit(1): fix always true condition X-Git-Url: https://gitweb.dragonflybsd.org/dragonfly.git/commitdiff_plain/979bf340e7af0f936d89ff344d8fd656514d67f7 limit(1): fix always true condition --- diff --git a/usr.bin/limits/limits.c b/usr.bin/limits/limits.c index 8782a74cab..9bea41e4ed 100644 --- a/usr.bin/limits/limits.c +++ b/usr.bin/limits/limits.c @@ -465,7 +465,7 @@ main(int argc, char *argv[]) for (rcswhich = 0; rcswhich < RLIM_NLIMITS; rcswhich++) { if (doall || num_limits == 0 || which_limits[rcswhich] != 0) { - if (which_limits[rcswhich] == ANY || which_limits[rcswhich]) + if (which_limits[rcswhich] == ANY) which_limits[rcswhich] = type; if (shellparm[shelltype].lprm[rcswhich].pfx) { if (shellparm[shelltype].both && limits[rcswhich].rlim_cur == limits[rcswhich].rlim_max) {