Browse Source

child_process: handle ENOENT correctly on Windows

v0.9.12-release
Scott Blomquist 12 years ago
committed by isaacs
parent
commit
323120b5c9
  1. 4
      lib/child_process.js

4
lib/child_process.js

@ -884,9 +884,9 @@ ChildProcess.prototype.spawn = function(options) {
if (stdio.handle) {
// when i === 0 - we're dealing with stdin
// (which is the only one writable pipe)
stdio.socket = createSocket(stdio.handle, i > 0);
stdio.socket = createSocket(self.pid !== 0 ? stdio.handle : null, i > 0);
if (i > 0) {
if (i > 0 && self.pid !== 0) {
self._closesNeeded++;
stdio.socket.on('close', function() {
maybeClose(self);

Loading…
Cancel
Save