@geastack/apple 0.2.16 → 0.2.18
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -63,8 +63,11 @@ macos_build_pid_is_running() {
|
|
|
63
63
|
local pid="$1"
|
|
64
64
|
local state=""
|
|
65
65
|
kill -0 "$pid" 2>/dev/null || return 1
|
|
66
|
+
# kill -0 already proved the pid exists; only a zombie state rules it out. A
|
|
67
|
+
# ps that prints nothing (it can, on a loaded machine) must not read as dead,
|
|
68
|
+
# or the escalation below skips a live descendant that ignores TERM.
|
|
66
69
|
state="$(ps -o stat= -p "$pid" 2>/dev/null | awk 'NR == 1 { print $1 }')"
|
|
67
|
-
[[
|
|
70
|
+
[[ "$state" != Z* ]]
|
|
68
71
|
}
|
|
69
72
|
|
|
70
73
|
macos_terminate_and_reap_build_children() {
|