Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
// USE OR OTHER DEALINGS IN THE SOFTWARE.

'use strict';
const common = require('../common');
require('../common');
const assert = require('assert');
const fork = require('child_process').fork;
const net = require('net');
Expand Down Expand Up @@ -79,7 +79,7 @@ if (process.argv[2] === 'child') {
server.on('listening', function() {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: should this be a common.mustCall()?

let j = count;
while (j--) {
const client = net.connect(common.PORT, '127.0.0.1');
const client = net.connect(server.address().port, '127.0.0.1');
client.on('close', function() {
disconnected += 1;
});
Expand Down Expand Up @@ -110,7 +110,7 @@ if (process.argv[2] === 'child') {
closeEmitted = true;
});

server.listen(common.PORT, '127.0.0.1');
server.listen(0, '127.0.0.1');

process.on('exit', function() {
assert.strictEqual(sent, count);
Expand Down