From 95c20bbe2252bca6ea0d929f2930cd9cbe9f84bf Mon Sep 17 00:00:00 2001 From: Sebastien Luttringer Date: Fri, 1 Apr 2011 18:43:40 +0200 Subject: Fix incomplete daemon detection in have_daemon A daemon is an executable _file_ in /etc/rc.d. Directory like functions.d is not a daemon. Signed-off-by: Sebastien Luttringer --- functions | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/functions b/functions index e4d46d0..2c3a6d5 100644 --- a/functions +++ b/functions @@ -170,8 +170,9 @@ ck_daemon() { [[ ! -f /run/daemons/$1 ]] } +# Check if $1 is a valid daemon name have_daemon() { - [[ -x /etc/rc.d/$1 ]] + [[ -f /etc/rc.d/$1 && -x /etc/rc.d/$1 ]] } start_daemon() { -- cgit v1.2.3