Browse Source

Improved etc/rc.d/functions.in's status to also support $? as first argument instead of $error

early
Alejandro Mery 17 years ago
parent
commit
22e35e76e2
  1. 4
      base/sysfiles/etc_rc.d_functions.in.txt

4
base/sysfiles/etc_rc.d_functions.in.txt

@ -2,7 +2,7 @@
# This copyright note is auto-generated by ./scripts/Create-CopyPatch.
#
# Filename: package/.../sysfiles/etc_rc.d_functions.in.txt
# Copyright (C) 2006 - 2007 The OpenSDE Project
# Copyright (C) 2006 - 2008 The OpenSDE Project
#
# More information can be found in the files COPYING and README.
#
@ -54,7 +54,7 @@ title() {
status() {
$ECHO -n "$MOVE_UP$MOVE_EOL$MOVE_LEFT_STATUS"
if [ $error -eq 0 ]; then
if [ ${1:-error} -eq 0 ]; then
$ECHO "$COLOR_SUCCESS$ART_SUCCESS$COLOR_NORMAL"
else
$ECHO "$BELL$COLOR_FAILURE$ART_FAILURE$COLOR_NORMAL"

Loading…
Cancel
Save