From 563791e39b7b5faf4456db0f90f172c20542eec4 Mon Sep 17 00:00:00 2001 From: Robert Nagy Date: Thu, 24 Mar 2011 07:28:32 +0000 Subject: if daemon_flags=NO is set, just exit ok ajacoutot@ --- etc/rc.d/rc.subr | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'etc/rc.d') diff --git a/etc/rc.d/rc.subr b/etc/rc.d/rc.subr index b62cf54f390..24d9eca9212 100644 --- a/etc/rc.d/rc.subr +++ b/etc/rc.d/rc.subr @@ -1,4 +1,4 @@ -# $OpenBSD: rc.subr,v 1.28 2011/03/19 19:03:57 ian Exp $ +# $OpenBSD: rc.subr,v 1.29 2011/03/24 07:28:31 robert Exp $ # Default functions and variables used by rc.d(8) scripts. @@ -51,6 +51,8 @@ rc_cmd() { [ $(id -u) -eq 0 ] || \ rc_err "$0: need root privileges" + [ X"${daemon_flags}" = X"NO" ] && exit 1 + eval _enotsup=\${rc_${1}} [ X"${_enotsup}" != X"NO" ] || rc_err "$0: $1 is not supported" -- cgit v1.2.3