diff --git a/lib/child_process.js b/lib/child_process.js index 52435913e9..e67615d21b 100644 --- a/lib/child_process.js +++ b/lib/child_process.js @@ -337,6 +337,7 @@ function setupChannel(target, channel) { var message = JSON.parse(json); handleMessage(target, message, recvHandle); + recvHandle = undefined; start = i + 1; } diff --git a/test/simple/test-child-process-fork-getconnections.js b/test/simple/test-child-process-fork-getconnections.js index 326c6d9f6c..ad04dd7336 100644 --- a/test/simple/test-child-process-fork-getconnections.js +++ b/test/simple/test-child-process-fork-getconnections.js @@ -35,6 +35,7 @@ if (process.argv[2] === 'child') { } if (m.cmd === 'close') { + assert.equal(socket, undefined); sockets[m.id].once('close', function() { process.send({ id: m.id, status: 'closed' }); });