update comments

Avoiding multiple PID values ​​and triggering parameter passing errors

Signed-off-by: Teddysun <i@teddysun.com>
This commit is contained in:
Teddysun 2017-07-22 15:29:15 +09:00
parent 7a8a8ed44d
commit d3de7db4c2
No known key found for this signature in database
GPG Key ID: 09BD4C080AD6C46D
2 changed files with 2 additions and 2 deletions

View File

@ -29,7 +29,7 @@ RETVAL=0
check_running(){
PID=`ps -ef | grep -v grep | grep -i "${BIN}" | awk '{print $2}'`
if [ ! -z $PID ]; then
if [ ! -z "$PID" ]; then
return 0
else
return 1

View File

@ -27,7 +27,7 @@ RETVAL=0
check_running(){
PID=`ps -ef | grep -v grep | grep -i "${BIN}" | awk '{print $2}'`
if [ ! -z $PID ]; then
if [ ! -z "$PID" ]; then
return 0
else
return 1