From a29f501aa21b43ad0e7d29d3ed82c8b71b77007b Mon Sep 17 00:00:00 2001 From: Minwoo Jung Date: Sat, 21 Nov 2015 15:52:53 +0900 Subject: [PATCH] benchmark: add a constant declaration for `net` Constant declaration for `net` is omitted in `idle_server.js` Add a constant declaration for constant `net` PR-URL: https://github.com/nodejs/node/pull/3950 Reviewed-By: James M Snell Reviewed-By: Roman Reiss --- benchmark/idle_server.js | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/benchmark/idle_server.js b/benchmark/idle_server.js index a4c70d76d36ffe..805c988811ea50 100644 --- a/benchmark/idle_server.js +++ b/benchmark/idle_server.js @@ -1,12 +1,13 @@ -net = require('net'); -connections = 0; +'use strict'; +const net = require('net'); +var connections = 0; var errors = 0; -server = net.Server(function (socket) { +var server = net.Server(function (socket) { socket.on('error', function () { - errors++; + errors++; }); }); @@ -28,4 +29,3 @@ setInterval(function () { console.log("SERVER %d errors: %d", process.pid, errors); } }, 1000); -