Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 7da01f4

Browse filesBrowse files
BridgeARMylesBorins
authored andcommitted
benchmark: fix variables not being set
Due to the destructuring the outer variables were not set anymore. PR-URL: #18320 Reviewed-By: James M Snell <jasnell@gmail.com>
1 parent 4a5d7d4 commit 7da01f4
Copy full SHA for 7da01f4

File tree

Expand file treeCollapse file tree

1 file changed

+4
-3
lines changed
Open diff view settings
Filter options
Expand file treeCollapse file tree

1 file changed

+4
-3
lines changed
Open diff view settings
Collapse file

‎benchmark/tls/tls-connect.js‎

Copy file name to clipboardExpand all lines: benchmark/tls/tls-connect.js
+4-3Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,13 @@ const bench = common.createBenchmark(main, {
1111

1212
var clientConn = 0;
1313
var serverConn = 0;
14-
var server;
1514
var dur;
1615
var concurrency;
1716
var running = true;
1817

19-
function main({ dur, concurrency }) {
18+
function main(conf) {
19+
dur = conf.dur;
20+
concurrency = conf.concurrency;
2021
const cert_dir = path.resolve(__dirname, '../../test/fixtures');
2122
const options = {
2223
key: fs.readFileSync(`${cert_dir}/test_key.pem`),
@@ -25,7 +26,7 @@ function main({ dur, concurrency }) {
2526
ciphers: 'AES256-GCM-SHA384'
2627
};
2728

28-
server = tls.createServer(options, onConnection);
29+
const server = tls.createServer(options, onConnection);
2930
server.listen(common.PORT, onListening);
3031
}
3132

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.