fixes
This commit is contained in:
parent
3c42aff8f5
commit
fd8ad9799b
@ -8,13 +8,12 @@ function g_kill_all_background_jobs {
|
|||||||
then
|
then
|
||||||
kill -9 ${g_pids[*]} >/dev/null 2>&1
|
kill -9 ${g_pids[*]} >/dev/null 2>&1
|
||||||
else
|
else
|
||||||
local g_cmdline=$1
|
local g_cmdline="$1"
|
||||||
local g_proc
|
local g_proc
|
||||||
local g_pid
|
local g_pid
|
||||||
for g_pid in "${g_pids[@]}"
|
for g_pid in "${g_pids[@]}"
|
||||||
do
|
do
|
||||||
echo $g_pid
|
read g_proc < <(tr "\0" " " < /proc/${f_pid}/cmdline)
|
||||||
readarray g_proc < "/proc/$g_pid/cmdline"
|
|
||||||
[ "$g_proc" = "$g_cmdline" ] && kill -9 $g_pid >/dev/null 2>&1
|
[ "$g_proc" = "$g_cmdline" ] && kill -9 $g_pid >/dev/null 2>&1
|
||||||
done
|
done
|
||||||
fi
|
fi
|
||||||
|
Loading…
Reference in New Issue
Block a user