zarro 1.121.0 → 1.121.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -84,6 +84,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
84
84
  if (exited) {
85
85
  return;
86
86
  }
87
+ destroyPipesOn(child);
87
88
  exited = true;
88
89
  debug(`child ${eventName}s: ${code}`);
89
90
  result.exitCode = code;
@@ -131,5 +132,12 @@ Object.defineProperty(exports, "__esModule", { value: true });
131
132
  stream.on("data", handle);
132
133
  }
133
134
  }
135
+ function destroyPipesOn(child) {
136
+ for (const pipe of [child.stdout, child.stderr, child.stdin]) {
137
+ if (pipe) {
138
+ pipe.destroy();
139
+ }
140
+ }
141
+ }
134
142
  module.exports = spawn;
135
143
  })();
@@ -1,5 +1,6 @@
1
1
  import { IoConsumer } from "./exec";
2
2
  import { Readable } from "stream";
3
+ import { ChildProcess } from "child_process";
3
4
 
4
5
  (function() {
5
6
  // use for spawning actual processes.
@@ -105,6 +106,7 @@ import { Readable } from "stream";
105
106
  if (exited) {
106
107
  return;
107
108
  }
109
+ destroyPipesOn(child);
108
110
  exited = true;
109
111
  debug(`child ${ eventName }s: ${ code }`);
110
112
  result.exitCode = code;
@@ -161,5 +163,13 @@ import { Readable } from "stream";
161
163
 
162
164
  }
163
165
 
166
+ function destroyPipesOn(child: ChildProcess) {
167
+ for (const pipe of [child.stdout, child.stderr, child.stdin]) {
168
+ if (pipe) {
169
+ pipe.destroy();
170
+ }
171
+ }
172
+ }
173
+
164
174
  module.exports = spawn;
165
175
  })();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "zarro",
3
- "version": "1.121.0",
3
+ "version": "1.121.1",
4
4
  "description": "Some glue to make gulp easier, perhaps even zero- or close-to-zero-conf",
5
5
  "bin": {
6
6
  "zarro": "./index.js"