From owner-cvs-all@FreeBSD.ORG Sat Feb 2 19:53:50 2008 Return-Path: Delivered-To: cvs-all@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 725DD16A421; Sat, 2 Feb 2008 19:53:50 +0000 (UTC) (envelope-from simon@zaphod.nitro.dk) Received: from mx.nitro.dk (zarniwoop.nitro.dk [83.92.207.38]) by mx1.freebsd.org (Postfix) with ESMTP id 28FC213C447; Sat, 2 Feb 2008 19:53:49 +0000 (UTC) (envelope-from simon@zaphod.nitro.dk) Received: from zaphod.nitro.dk (unknown [192.168.3.39]) by mx.nitro.dk (Postfix) with ESMTP id 265822DD420; Sat, 2 Feb 2008 19:53:37 +0000 (UTC) Received: by zaphod.nitro.dk (Postfix, from userid 3000) id 7F28B11492; Sat, 2 Feb 2008 20:53:48 +0100 (CET) Date: Sat, 2 Feb 2008 20:53:48 +0100 From: "Simon L. Nielsen" To: Ceri Davies Message-ID: <20080202195347.GE11904@zaphod.nitro.dk> References: <200802021227.m12CRcZ9008161@repoman.freebsd.org> <20080202145321.GH6064@submonkey.net> <20080202160451.GD11904@zaphod.nitro.dk> <47A49FBF.2010301@dlr.de> <20080202193344.GI6064@submonkey.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20080202193344.GI6064@submonkey.net> User-Agent: Mutt/1.5.16 (2007-06-09) Cc: cvs-src@FreeBSD.org, Hartmut Brandt , src-committers@FreeBSD.org, cvs-all@FreeBSD.org, Dag-Erling Smorgrav Subject: Re: cvs commit: src/etc/periodic/security 100.chksetuid X-BeenThere: cvs-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: CVS commit messages for the entire tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 02 Feb 2008 19:53:50 -0000 On 2008.02.02 19:33:44 +0000, Ceri Davies wrote: > On Sat, Feb 02, 2008 at 05:52:15PM +0100, Hartmut Brandt wrote: > > Simon L. Nielsen wrote: > >> On 2008.02.02 14:53:21 +0000, Ceri Davies wrote: > >>> On Sat, Feb 02, 2008 at 12:27:38PM +0000, Dag-Erling Smorgrav wrote: > >>>> des 2008-02-02 12:27:38 UTC > >>>> > >>>> FreeBSD src repository > >>>> > >>>> Modified files: > >>>> etc/periodic/security 100.chksetuid Log: > >>>> Rewrite to consume significantly less memory, by using find -s instead of > >>>> find | sort. As a bonus, this simplifies the logic considerably. Also > >>>> remove the bogus "overruning the args to ls" comment and the corresponding > >>>> "-n 20" argument to xargs; the whole point with xargs is precisely that it > >>>> knows how large the argument list can safely get. > >>> Why use xargs at all? The "-exec ls -liTd {} +" primary would do the > >>> same thing. > >> > >> You would end up executing ls a lot more times with the extra overhead > >> for fork() etc. per file. > > > > I think "-exec ... {} +" collects as much arguments before executing just > > as xargs does. This is different from "-exec ... {} ;" which execs for each > > argument. > > Exactly my point, yes. I have never sumbled onto the "+" version only ";" so I just read it as ";". You (hopefully) learn something new everyday :-). -- Simon L. Nielsen