From owner-cvs-all Sun Sep 30 12:39:57 2001 Delivered-To: cvs-all@freebsd.org Received: from day.anthologeek.net (day.anthologeek.net [212.43.217.20]) by hub.freebsd.org (Postfix) with ESMTP id F0A5A37B406; Sun, 30 Sep 2001 12:39:51 -0700 (PDT) Received: by day.anthologeek.net (Postfix, from userid 1000) id 0E4C0171E3; Sun, 30 Sep 2001 21:39:05 +0200 (CEST) Date: Sun, 30 Sep 2001 21:39:05 +0200 From: Sameh Ghane To: Will Andrews Cc: cvs-committers@FreeBSD.ORG, cvs-all@FreeBSD.ORG Subject: Re: cvs commit: src/etc rc Message-ID: <20010930213904.A5966@anthologeek.net> References: <200109250155.f8P1tMR19221@freefall.freebsd.org> <20010930160801.A30603@alaska.cert.siemens.de> <20010930122429.G40556@curie.physics.purdue.edu> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <20010930122429.G40556@curie.physics.purdue.edu>; from will@physics.purdue.edu on Sun, Sep 30, 2001 at 12:24:29PM -0500 X-PGP-Keys: 0x1289F00D: Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Le (On) Sun, Sep 30, 2001 at 12:24:29PM -0500, Will Andrews ecrivit (wrote): > Shouldn't that be: > > > --- rc.orig Sun Sep 30 15:39:29 2001 > > +++ rc Sun Sep 30 15:53:33 2001 > > @@ -807,7 +807,9 @@ > > trap 'exit 1' 2 > > ${script} start) > > else > > - echo "Skipping ${script}, not executable" > > + if [ -f "${script}" ]; then > if [ ! -x '${script}" ]; then > > > + echo "Skipping ${script}, not executable" > > + fi > > fi > > done > > IFS="${script_save_sep}" Not needed, as the 'if' statement already deals with executables: if [ -x "${script}" ]; then (set -T trap 'exit 1' 2 ${script} start) else # If you are here, ${script} is not executable or non-existent. echo "Skipping ${script}, not executable" fi So test -f is enough. Cheers, -- Sameh To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message