MCPcopy Index your code
hub / github.com/nodejs/node / cleanup

Function cleanup

lib/internal/child_process.js:1028–1033  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1026 // (i.e. PipeWraps or fds)
1027 stdio = ArrayPrototypeReduce(stdio, (acc, stdio, i) => {
1028 function cleanup() {
1029 for (let i = 0; i < acc.length; i++) {
1030 if ((acc[i].type === 'pipe' || acc[i].type === 'ipc') && acc[i].handle)
1031 acc[i].handle.close();
1032 }
1033 }
1034
1035 // Defaults
1036 stdio ??= i < 3 ? 'pipe' : 'ignore';

Callers 1

getValidStdioFunction · 0.70

Calls 1

closeMethod · 0.65

Tested by

no test coverage detected