diff options
author | FlorentCoppint <FlorentCoppint@users.noreply.github.com> | 2017-09-16 14:58:04 +0300 |
---|---|---|
committer | Michael Boelen <michael.boelen@cisofy.com> | 2017-09-16 14:58:04 +0300 |
commit | ccf9db18f85e480ed18dfd2d502b23f017fd0767 (patch) | |
tree | 4b5d4fd0ba5123ccddf1fb9c484676e6f33066f7 | |
parent | 79278c32ef98fe7294ad8663c80da209d6f66a4e (diff) |
Improved IsRunning() process matching (#463)
-rw-r--r-- | include/functions | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/include/functions b/include/functions index 72ea9340..1f073112 100644 --- a/include/functions +++ b/include/functions @@ -1245,8 +1245,8 @@ IsRunning() { if [ $# -eq 0 ]; then ExitFatal "Missing parameter when calling IsRunning function"; fi RUNNING=0 - PSOPTIONS="" - if [ ${SHELL_IS_BUSYBOX} -eq 0 ]; then PSOPTIONS=" ax"; fi + PSOPTIONS=" -o args=" + if [ ${SHELL_IS_BUSYBOX} -eq 0 ]; then PSOPTIONS=" -o args= -C $1"; fi FIND=$(${PSBINARY} ${PSOPTIONS} | egrep "( |/)$1" | grep -v "grep") if [ ! "${FIND}" = "" ]; then RUNNING=1 |