MCPcopy Index your code
hub / github.com/coder/mux / terminateCloneProcess

Method terminateCloneProcess

src/node/services/projectService.ts:738–753  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

736 }
737
738 const terminateCloneProcess = () => {
739 if (child.killed || child.exitCode !== null || child.signalCode !== null) {
740 return;
741 }
742
743 if (typeof child.pid === "number" && child.pid > 0) {
744 killProcessTree(child.pid);
745 return;
746 }
747
748 try {
749 child.kill();
750 } catch {
751 // Ignore ESRCH races if process exits between checks.
752 }
753 };
754
755 const onAbort = () => {
756 terminateCloneProcess();

Callers

nothing calls this directly

Calls 2

killProcessTreeFunction · 0.90
killMethod · 0.65

Tested by

no test coverage detected