Checking pid doesn't contain 0
This commit is contained in:
parent
ee8b213894
commit
ab40ea64e2
|
@ -3,7 +3,7 @@
|
||||||
#### OFUNCTIONS MINI SUBSET ####
|
#### OFUNCTIONS MINI SUBSET ####
|
||||||
|
|
||||||
_OFUNCTIONS_VERSION=2.1.4-dev
|
_OFUNCTIONS_VERSION=2.1.4-dev
|
||||||
_OFUNCTIONS_BUILD=2017052804
|
_OFUNCTIONS_BUILD=2017052901
|
||||||
#### _OFUNCTIONS_BOOTSTRAP SUBSET ####
|
#### _OFUNCTIONS_BOOTSTRAP SUBSET ####
|
||||||
_OFUNCTIONS_BOOTSTRAP=true
|
_OFUNCTIONS_BOOTSTRAP=true
|
||||||
#### _OFUNCTIONS_BOOTSTRAP SUBSET END ####
|
#### _OFUNCTIONS_BOOTSTRAP SUBSET END ####
|
||||||
|
@ -317,7 +317,7 @@ function KillChilds {
|
||||||
local pid="${1}" # Parent pid to kill childs
|
local pid="${1}" # Parent pid to kill childs
|
||||||
local self="${2:-false}" # Should parent be killed too ?
|
local self="${2:-false}" # Should parent be killed too ?
|
||||||
|
|
||||||
if [ $(IsNumeric "$pid") -eq 0 ] || [ "$pid" == "" ]; then
|
if [ $(IsNumeric "$pid") -eq 0 ] || [ "$pid" == "" ] || [ "$pid" == "0" ]; then
|
||||||
Logger "Bogus pid given [$pid]." "CRITICAL"
|
Logger "Bogus pid given [$pid]." "CRITICAL"
|
||||||
return 1
|
return 1
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Reference in New Issue