scstadmin: Make /etc/init.d/scst status work on RHEL 6.2. Apparently RHEL 6.2 doesn't define the function rc_status in /lib/lsb/init-functions.

git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@4163 d57e44dd-8a1f-0410-8b47-8ef2f437770f
This commit is contained in:
Bart Van Assche
2012-03-18 12:05:45 +00:00
parent 8dc9d5c439
commit 81fff819d6
+5 -4
View File
@@ -79,9 +79,7 @@ cat <<"EOF"
SCST_CFG=/etc/scst.conf
if [ ! -e /lib/lsb/init-functions ]; then
# Slackware and Gentoo.
rc_status() {
show_status() {
_rc_status_ret=$?
for i; do
case "$i" in
@@ -95,6 +93,9 @@ rc_status() {
done
return ${_rc_status_ret}
}
if [ ! -e /lib/lsb/init-functions ]; then
# Slackware and Gentoo.
start_daemon() {
"$@" >/dev/null 2>&1 &
}
@@ -332,7 +333,7 @@ case "$1" in
## Print the current status of the service.
echo -n "SCST status: "
scst_status >/dev/null 2>&1
rc_status -v
show_status -v
exit $?
;;
*)