Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 1 Oct 2001 09:27:17 +0200
From:      Udo Schweigert <udo.schweigert@siemens.com>
To:        "David O'Brien" <obrien@FreeBSD.ORG>
Cc:        cvs-committers@FreeBSD.ORG, cvs-all@FreeBSD.ORG
Subject:   Re: cvs commit: src/etc rc
Message-ID:  <20011001092717.A57657@alaska.cert.siemens.de>
In-Reply-To: <20010930150859.B85562@dragon.nuxi.com>
References:  <200109250155.f8P1tMR19221@freefall.freebsd.org> <20010930160801.A30603@alaska.cert.siemens.de> <20010930150859.B85562@dragon.nuxi.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sun, Sep 30, 2001 at 15:08:59 -0700, David O'Brien wrote:
> On Sun, Sep 30, 2001 at 04:08:01PM +0200, Udo Schweigert wrote:
>> This gives a message if the startup directory is empty. The attached patch
>> fixes this.
> 
> Great!  I knew about the bug. I'm ashamed to admit this fix did not come
> to mind as a way to fix it.
> 
Sorry for again replying, but I not saw Dag's suggestion before. Here is a
patch which also does the right echo command and handles the file globbing.

Best regards

--
Udo Schweigert, Siemens AG   | Voice      : +49 89 636 42170
CT IC 3, Siemens CERT        | Fax        : +49 89 636 41166
D-81730 Muenchen / Germany   | email      : udo.schweigert@siemens.com

--- /usr/src/etc/rc	Mon Oct  1 07:11:03 2001
+++ rc	Mon Oct  1 09:23:40 2001
@@ -795,7 +795,9 @@
 	for dir in ${local_startup}; do
 		if [ -d "${dir}" ]; then
 			for script in ${dir}/*.sh; do
-				slist="${slist}${script_name_sep}${script}"
+				if [ "${script}" != "${dir}/*.sh" ]; then
+				    slist="${slist}${script_name_sep}${script}"
+				fi
 			done
 		fi
 	done
@@ -806,8 +808,8 @@
 			(set -T
 			trap 'exit 1' 2
 			${script} start)
-		elif [ -f "${script}" ]; then
-			echo "Skipping ${script}, not executable"
+		else
+			echo -n " (skipping ${script##*/})"
 		fi
 	done
 	IFS="${script_save_sep}"

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe cvs-all" in the body of the message




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