MCPcopy Index your code
hub / github.com/callstack/agent-device / isLiveProcessLockOwner

Function isLiveProcessLockOwner

src/utils/process-lock.ts:125–136  ·  view source on GitHub ↗
(owner: ProcessLockOwner)

Source from the content-addressed store, hash-verified

123}
124
125function isLiveProcessLockOwner(owner: ProcessLockOwner): boolean {
126 if (!Number.isInteger(owner.pid) || owner.pid <= 0) {
127 return false;
128 }
129 if (!isProcessAlive(owner.pid)) {
130 return false;
131 }
132 if (owner.startTime) {
133 return readProcessStartTime(owner.pid) === owner.startTime;
134 }
135 return true;
136}

Callers 1

clearStaleProcessLockFunction · 0.85

Calls 2

isProcessAliveFunction · 0.90
readProcessStartTimeFunction · 0.90

Tested by

no test coverage detected