ps --pid isn't supported by BusyBox
This commit is contained in:
parent
8930b1d426
commit
7cf168896c
@ -14,7 +14,7 @@ if [[ -e $file ]]; then
|
|||||||
pidenv=`cat $file | grep SSH_AGENT_PID`
|
pidenv=`cat $file | grep SSH_AGENT_PID`
|
||||||
pid=`printf "$pidenv" | grep -o "[0-9]*"`
|
pid=`printf "$pidenv" | grep -o "[0-9]*"`
|
||||||
|
|
||||||
ps --pid "$pid" &> /dev/null
|
kill -0 "$pid" &> /dev/null
|
||||||
if (( ! $? )); then
|
if (( ! $? )); then
|
||||||
export "$sockenv"
|
export "$sockenv"
|
||||||
export "$pidenv"
|
export "$pidenv"
|
||||||
|
Loading…
Reference in New Issue
Block a user