Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 21 Jan 2018 08:48:26 +0000 (UTC)
From:      Eitan Adler <eadler@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r328212 - head/usr.bin/limits
Message-ID:  <201801210848.w0L8mQA4008418@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: eadler
Date: Sun Jan 21 08:48:26 2018
New Revision: 328212
URL: https://svnweb.freebsd.org/changeset/base/328212

Log:
  limits(1): fix always true condition
  
  Reviewed by:	imp
  MFC After:	1 week

Modified:
  head/usr.bin/limits/limits.c

Modified: head/usr.bin/limits/limits.c
==============================================================================
--- head/usr.bin/limits/limits.c	Sun Jan 21 04:57:29 2018	(r328211)
+++ head/usr.bin/limits/limits.c	Sun Jan 21 08:48:26 2018	(r328212)
@@ -509,7 +509,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) {



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201801210848.w0L8mQA4008418>