fix(process): gate sampling on initialized PTY root

This commit is contained in:
N0zoM1z0
2026-07-15 06:16:37 +08:00
committed by morluto
parent 072ce5aede
commit 57938a8465
4 changed files with 151 additions and 19 deletions
+7
View File
@@ -104,6 +104,13 @@ const systemHost: ProcessOwnershipHost = {
},
};
/** Read the capture run token currently exposed by one live process. */
export const readProcessRunId = async (
pid: number,
host: ProcessOwnershipHost = systemHost,
): Promise<string | undefined> =>
(await host.environment(pid)).REA_PROCESS_RUN_ID;
/**
* Verify run-token ownership before signaling a POSIX process group.
*