diff options
author | Joe Marcus Clarke <marcus@FreeBSD.org> | 2004-07-26 20:12:57 +0000 |
---|---|---|
committer | Joe Marcus Clarke <marcus@FreeBSD.org> | 2004-07-26 20:12:57 +0000 |
commit | 2df64761c8d0a5e2d412352e314f6ad0779c8916 (patch) | |
tree | 5e8eebdc7ebb24bdedc2d1c9e78aa86534228cb1 /net/openslp | |
parent | b3eb115f52fa44955a976b7b9fe7e6268834c200 (diff) |
Use a safer way of initializing default rc.d variables.
Submitted by: mtm
Notes
Notes:
svn path=/head/; revision=114799
Diffstat (limited to 'net/openslp')
-rw-r--r-- | net/openslp/files/slpd.in | 6 | ||||
-rw-r--r-- | net/openslp/files/slpd.sh.sample | 6 |
2 files changed, 6 insertions, 6 deletions
diff --git a/net/openslp/files/slpd.in b/net/openslp/files/slpd.in index 005d18921a5d..4fe3d0826913 100644 --- a/net/openslp/files/slpd.in +++ b/net/openslp/files/slpd.in @@ -11,6 +11,9 @@ # slpd_enable="YES" # +slpd_enable=${slpd_enable-"NO"} +slpd_flags=${slpd_flags-"-p /var/run/slpd.pid"} + . %%RC_SUBR%% name=slpd @@ -19,8 +22,5 @@ rcvar=`set_rcvar` command=%%PREFIX%%/sbin/slpd pidfile="/var/run/${name}.pid" -[ -z "$slpd_enable" ] && slpd_enable="NO" -[ -z "$slpd_flags" ] && slpd_flags="-p /var/run/slpd.pid" - load_rc_config ${name} run_rc_command "$1" diff --git a/net/openslp/files/slpd.sh.sample b/net/openslp/files/slpd.sh.sample index 005d18921a5d..4fe3d0826913 100644 --- a/net/openslp/files/slpd.sh.sample +++ b/net/openslp/files/slpd.sh.sample @@ -11,6 +11,9 @@ # slpd_enable="YES" # +slpd_enable=${slpd_enable-"NO"} +slpd_flags=${slpd_flags-"-p /var/run/slpd.pid"} + . %%RC_SUBR%% name=slpd @@ -19,8 +22,5 @@ rcvar=`set_rcvar` command=%%PREFIX%%/sbin/slpd pidfile="/var/run/${name}.pid" -[ -z "$slpd_enable" ] && slpd_enable="NO" -[ -z "$slpd_flags" ] && slpd_flags="-p /var/run/slpd.pid" - load_rc_config ${name} run_rc_command "$1" |