diff --git a/lgsm/functions/command_stop.sh b/lgsm/functions/command_stop.sh index 46c1d55ed..44bf94359 100644 --- a/lgsm/functions/command_stop.sh +++ b/lgsm/functions/command_stop.sh @@ -219,7 +219,7 @@ fn_stop_ark(){ if [ "${#queryport}" -gt 0 ] ; then for (( pidcheck=0 ; pidcheck < ${maxpiditer} ; pidcheck++ )) ; do pid=$(netstat -nap 2>/dev/null | grep ^udp[[:space:]] |\ - grep :${queryport}[[:space:]] | rev | awk '{print $1}' |\ + grep ":${queryport}[[:space:]]" | rev | awk '{print $1}' |\ rev | cut -d\/ -f1) # # check for a valid pid