diff options
Diffstat (limited to 'sbin')
-rwxr-xr-x | sbin/functions.sh | 4 | ||||
-rwxr-xr-x | sbin/runscript.sh | 5 |
2 files changed, 5 insertions, 4 deletions
diff --git a/sbin/functions.sh b/sbin/functions.sh index e8d2d4e..423ada6 100755 --- a/sbin/functions.sh +++ b/sbin/functions.sh @@ -610,10 +610,10 @@ is_older_than() { shift for x in "$@" ; do - [[ ${x} -nt "${ref}" ]] && return 0 - if [[ -d ${x} ]] ; then is_older_than "${ref}" "${x}"/* && return 0 + elif [[ ${x} -nt ${ref} ]] ; then + return 0 fi done diff --git a/sbin/runscript.sh b/sbin/runscript.sh index 9614529..a54ff67 100755 --- a/sbin/runscript.sh +++ b/sbin/runscript.sh @@ -27,13 +27,14 @@ myservice="${SVCNAME}" # until after rc sysinit has completed so we punt them to the boot runlevel if [[ -e /dev/.rcsysinit ]] ; then eerror "ERROR: cannot run ${SVCNAME} until sysinit completes" - [[ ${RC_COLDPLUG} == "no" ]] && exit 1 - if [[ ${RC_COLDPLUG} != "yes" ]] ; then + [[ "${RC_COLDPLUG} " == "!* "* ]] && exit 1 + if [[ "${RC_COLDPLUG} " != "* "* ]] ; then for x in ${RC_COLDPLUG} ; do # We don't quote ${x} so we can do globbing [[ ${SVCNAME} == ${x} ]] && break [[ "!${SVCNAME}" == ${x} ]] && exit 1 done + [[ ${SVCNAME} == ${x} ]] || exit 1 fi eerror "${SVCNAME} will be started in the ${BOOTLEVEL} runlevel" if [[ ! -L /dev/.rcboot/"${SVCNAME}" ]] ; then |