Browse Source

test: use the new net.listen(backlog=x) API

v0.9.1-release
Ben Noordhuis 13 years ago
parent
commit
c56d1559fc
  1. 5
      test/fixtures/fork2.js
  2. 5
      test/simple/test-child-process-fork2.js

5
test/fixtures/fork2.js

@ -16,10 +16,7 @@ process.on('message', function(m, serverHandle) {
process.send({ childConnections: connections }); process.send({ childConnections: connections });
}); });
// TODO need better API for this. server.listen(serverHandle, /* backlog */ 9, function() {
server._backlog = 9;
server.listen(serverHandle, function() {
process.send({ gotHandle: true }); process.send({ gotHandle: true });
}); });
}); });

5
test/simple/test-child-process-fork2.js

@ -36,10 +36,7 @@ var server = new net.Server(function(c) {
c.destroy(); c.destroy();
}); });
// TODO need better API for this. server.listen(common.PORT, /* backlog */ 9, function() {
server._backlog = 9;
server.listen(common.PORT, function() {
console.log('PARENT send child server handle'); console.log('PARENT send child server handle');
n.send({ hello: 'world' }, server._handle); n.send({ hello: 'world' }, server._handle);
}); });

Loading…
Cancel
Save