MCPcopy
hub / github.com/microsoft/playwright / addProcessHandlerIfNeeded

Function addProcessHandlerIfNeeded

packages/utils/processLauncher.ts:117–122  ·  view source on GitHub ↗
(name: 'exit' | 'SIGINT' | 'SIGTERM' | 'SIGHUP')

Source from the content-addressed store, hash-verified

115 SIGHUP: sighupHandler,
116};
117function addProcessHandlerIfNeeded(name: 'exit' | 'SIGINT' | 'SIGTERM' | 'SIGHUP') {
118 if (!installedHandlers.has(name)) {
119 installedHandlers.add(name);
120 process.on(name, processHandlers[name]);
121 }
122}
123function removeProcessHandlersIfNeeded() {
124 if (killSet.size)
125 return;

Callers 1

launchProcessFunction · 0.85

Calls 3

hasMethod · 0.80
onMethod · 0.65
addMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…