aboutsummaryrefslogtreecommitdiffstats
path: root/rc.d/init.d/functions
diff options
context:
space:
mode:
authorDavid Kaspar [Dee'Kej] <dkaspar@redhat.com>2016-10-11 16:55:00 +0200
committerLukáš Nykrýn <lnykryn@redhat.com>2016-10-12 22:00:19 +0200
commitc43cefb7afbb096ca572b07bf03760e7eab74804 (patch)
treef1dc8aeb0174b82ad94e0a6893a1cc8ce72971ad /rc.d/init.d/functions
parent6a8383b971cf1f72eea6780291953c524c835ba0 (diff)
downloadinitscripts-c43cefb7afbb096ca572b07bf03760e7eab74804.tar
initscripts-c43cefb7afbb096ca572b07bf03760e7eab74804.tar.gz
initscripts-c43cefb7afbb096ca572b07bf03760e7eab74804.tar.bz2
initscripts-c43cefb7afbb096ca572b07bf03760e7eab74804.tar.xz
initscripts-c43cefb7afbb096ca572b07bf03760e7eab74804.zip
Support boolean values in is_true() & is_false() functions
Diffstat (limited to 'rc.d/init.d/functions')
-rw-r--r--rc.d/init.d/functions4
1 files changed, 2 insertions, 2 deletions
diff --git a/rc.d/init.d/functions b/rc.d/init.d/functions
index 788902c0..f378720e 100644
--- a/rc.d/init.d/functions
+++ b/rc.d/init.d/functions
@@ -603,7 +603,7 @@ is_ignored_file() {
# Evaluate shvar-style booleans
is_true() {
case "$1" in
- [tT] | [yY] | [yY][eE][sS] | [tT][rR][uU][eE])
+ [tT] | [yY] | [yY][eE][sS] | [tT][rR][uU][eE] | 1)
return 0
;;
esac
@@ -613,7 +613,7 @@ is_true() {
# Evaluate shvar-style booleans
is_false() {
case "$1" in
- [fF] | [nN] | [nN][oO] | [fF][aA][lL][sS][eE])
+ [fF] | [nN] | [nN][oO] | [fF][aA][lL][sS][eE] | 0)
return 0
;;
esac