- Jul 20, 2017
-
-
Ben Noordhuis authored
Replace allocate + Encode() + free patterns by calls to Malloc + the Buffer::New() overload that takes ownership of the pointer. Avoids unnecessary heap allocations and copying around of data. DRY the accessor functions for the prime, generator, public key and private key properties; deletes about 40 lines of quadruplicated code. PR-URL: https://github.com/nodejs/node/pull/14122 Reviewed-By:
Anna Henningsen <anna@addaleax.net> Reviewed-By:
James M Snell <jasnell@gmail.com>
-
Ben Noordhuis authored
Add a test that ensures the second call to .digest() returns an empty HMAC, like it did before. No comment on whether that is the right behavior or not. PR-URL: https://github.com/nodejs/node/pull/14122 Reviewed-By:
Anna Henningsen <anna@addaleax.net> Reviewed-By:
James M Snell <jasnell@gmail.com>
-
Ben Noordhuis authored
Don't allocate + copy + free; allocate and fill in place, then hand off the pointer to Buffer::New(). Avoids unnecessary heap allocations in the following methods: - crypto.CryptoStream#getSession() - tls.TLSSocket#getSession() PR-URL: https://github.com/nodejs/node/pull/14122 Reviewed-By:
Anna Henningsen <anna@addaleax.net> Reviewed-By:
James M Snell <jasnell@gmail.com>
-
Ben Noordhuis authored
The cipher kind doesn't change over the lifetime of the cipher so make it const. PR-URL: https://github.com/nodejs/node/pull/14122 Reviewed-By:
Anna Henningsen <anna@addaleax.net> Reviewed-By:
James M Snell <jasnell@gmail.com>
-
Ben Noordhuis authored
PR-URL: https://github.com/nodejs/node/pull/14122 Reviewed-By:
Anna Henningsen <anna@addaleax.net> Reviewed-By:
James M Snell <jasnell@gmail.com>
-
Ben Noordhuis authored
The EVP_CIPHER can be reconstructed from the EVP_CIPHER_CTX instance, no need to store it separately. This brought to light the somewhat dubious practice of accessing the EVP_CIPHER after the EVP_CIPHER_CTX instance had been destroyed. It's mostly harmless due to the static nature of built-in EVP_CIPHER instances but it segfaults when the cipher is provided by an ENGINE and the ENGINE is unloaded because its reference count drops to zero. PR-URL: https://github.com/nodejs/node/pull/14122 Reviewed-By:
Anna Henningsen <anna@addaleax.net> Reviewed-By:
James M Snell <jasnell@gmail.com>
-
Ben Noordhuis authored
Fix a memory leak by removing the heap allocation altogether. Fixes: https://github.com/nodejs/node/issues/13917 PR-URL: https://github.com/nodejs/node/pull/14122 Reviewed-By:
Anna Henningsen <anna@addaleax.net> Reviewed-By:
James M Snell <jasnell@gmail.com>
-
Ben Noordhuis authored
Put the 8 kB initial buffer on the stack first and don't copy it to the heap until its exact size is known (which is normally much smaller.) PR-URL: https://github.com/nodejs/node/pull/14122 Reviewed-By:
Anna Henningsen <anna@addaleax.net> Reviewed-By:
James M Snell <jasnell@gmail.com>
-
Ben Noordhuis authored
PR-URL: https://github.com/nodejs/node/pull/14122 Reviewed-By:
Anna Henningsen <anna@addaleax.net> Reviewed-By:
James M Snell <jasnell@gmail.com>
-
Ben Noordhuis authored
Don't allocate + copy + free; allocate and fill in place, then hand off the pointer to Buffer::New(). Avoids unnecessary heap allocations in the following methods: - crypto.Cipher#final() - crypto.Cipher#update() - crypto.Cipheriv#final() - crypto.Cipheriv#update() - crypto.Decipher#final() - crypto.Decipher#update() - crypto.Decipheriv#final() - crypto.Decipheriv#update() - crypto.privateDecrypt() - crypto.privateEncrypt() - crypto.publicDecrypt() - crypto.publicEncrypt() PR-URL: https://github.com/nodejs/node/pull/14122 Reviewed-By:
Anna Henningsen <anna@addaleax.net> Reviewed-By:
James M Snell <jasnell@gmail.com>
-
Nikolai Vavilov authored
VsDevCmd.bat changes the current working directory to "%USERPROFILE%\Source" if it exists. Setting VSCMD_START_DIR overrides this behavior. PR-URL: https://github.com/nodejs/node/pull/14303 Fixes: https://github.com/nodejs/node/issues/14300 Refs: https://developercommunity.visualstudio.com/content/problem/26780/vsdevcmdbat-changes-the-current-working-directory.html Reviewed-By:
Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By:
Refael Ackermann <refack@gmail.com> Reviewed-By:
Richard Lau <riclau@uk.ibm.com> Reviewed-By:
James M Snell <jasnell@gmail.com>
-
Sam Roberts authored
The ability to set the link rule is used for FIPS, and needs to set both the `ld =` and `ldxx =` variables in the ninja build file to link c++ (node) and c (openssl-cli, etc.) executables. URL: https://github.com/nodejs/node/pull/14227 Reviewed-By:
Refael Ackermann <refack@gmail.com> Reviewed-By:
Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By:
James M Snell <jasnell@gmail.com>
-
Roee Kasher authored
When an OutgoingMessage is closed (for example, using the `end` method), its 'writable' property should be changed to false - since it is not writable anymore. The 'writable' property should have the opposite value of the 'finished' property. PR-URL: https://github.com/nodejs/node/pull/14024 Fixes: https://github.com/nodejs/node/issues/14023 Reviewed-By:
Matteo Collina <matteo.collina@gmail.com> Reviewed-By:
Gireesh Punathil <gpunathi@in.ibm.com>
-
Gibson Fahnestock authored
PR-URL: https://github.com/nodejs/node/pull/14259 Fixes: https://github.com/nodejs/node/issues/10718 Reviewed-By:
Refael Ackermann <refack@gmail.com> Reviewed-By:
Timothy Gu <timothygu99@gmail.com> Reviewed-By:
James M Snell <jasnell@gmail.com>
-
Kat Marchán authored
This includes a critical fix to get npx working on Windows PR-URL: https://github.com/nodejs/node/pull/14235 Reviewed-By:
Jeremiah Senkpiel <fishrock123@rocketmail.com> Reviewed-By:
Refael Ackermann <refack@gmail.com> Reviewed-By:
Anna Henningsen <anna@addaleax.net> Reviewed-By:
Yuta Hiroto <hello@about-hiroppy.com> Reviewed-By:
Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By:
Tobias Nießen <tniessen@tnie.de> Reviewed-By:
James M Snell <jasnell@gmail.com>
-
Kat Marchán authored
PR-URL: https://github.com/nodejs/node/pull/14235 Reviewed-By:
Jeremiah Senkpiel <fishrock123@rocketmail.com> Reviewed-By:
Refael Ackermann <refack@gmail.com> Reviewed-By:
Anna Henningsen <anna@addaleax.net> Reviewed-By:
Yuta Hiroto <hello@about-hiroppy.com> Reviewed-By:
Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By:
Tobias Nießen <tniessen@tnie.de> Reviewed-By:
James M Snell <jasnell@gmail.com>
-
Kat Marchán authored
PR-URL: https://github.com/nodejs/node/pull/14235 Reviewed-By:
Jeremiah Senkpiel <fishrock123@rocketmail.com> Reviewed-By:
Refael Ackermann <refack@gmail.com> Reviewed-By:
Anna Henningsen <anna@addaleax.net> Reviewed-By:
Yuta Hiroto <hello@about-hiroppy.com> Reviewed-By:
Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By:
Tobias Nießen <tniessen@tnie.de> Reviewed-By:
James M Snell <jasnell@gmail.com>
-
Bradley Farias authored
It is not needed / invalidates the returned value unlike EscapableHandleScope PR-URL: https://github.com/nodejs/node/pull/14096 Reviewed-By:
Refael Ackermann <refack@gmail.com> Reviewed-By:
Anna Henningsen <anna@addaleax.net> Reviewed-By:
Timothy Gu <timothygu99@gmail.com> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com> Reviewed-By:
James M Snell <jasnell@gmail.com>
-
Superwoods authored
Replace constructor with regular expression for second argument to assert.throws() in test-util-format. PR-URL: https://github.com/nodejs/node/pull/14299 Reviewed-By:
Rich Trott <rtrott@gmail.com> Reviewed-By:
Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By:
Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com> Reviewed-By:
Tobias Nießen <tniessen@tnie.de> Reviewed-By:
Refael Ackermann <refack@gmail.com> Reviewed-By:
Gireesh Punathil <gpunathi@in.ibm.com>
-
boydfd authored
Replace string concatenation in test/parallel/test-cli-bad-options.js with template literal. Adjust argument layout for readability. PR-URL: https://github.com/nodejs/node/pull/14274 Reviewed-By:
Rich Trott <rtrott@gmail.com> Reviewed-By:
Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By:
Evan Lucas <evanlucas@me.com> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com> Reviewed-By:
Tobias Nießen <tniessen@tnie.de> Reviewed-By:
Refael Ackermann <refack@gmail.com> Reviewed-By:
Gireesh Punathil <gpunathi@in.ibm.com>
-
vercent deng authored
Use template literals instead of string concatenation in test/async-hooks/test-writewrap.js. PR-URL: https://github.com/nodejs/node/pull/14292 Reviewed-By:
Rich Trott <rtrott@gmail.com> Reviewed-By:
Michaël Zasso <targos@protonmail.com> Reviewed-By:
Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By:
Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com> Reviewed-By:
Tobias Nießen <tniessen@tnie.de> Reviewed-By:
Gireesh Punathil <gpunathi@in.ibm.com>
-
xinglong.wangwxl authored
test/parallel/test-catpto-random.js contains an object called errorMesssage that contains regular expressions.They are only partially matching regular expressions. Make them match the entire error message. PR-URL: https://github.com/nodejs/node/pull/14271 Reviewed-By:
Rich Trott <rtrott@gmail.com> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com> Reviewed-By:
Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By:
Tobias Nießen <tniessen@tnie.de> Reviewed-By:
Gireesh Punathil <gpunathi@in.ibm.com>
-
weiyuanyue authored
Replace string concatenation with template literals in test/async-hooks/verify-graph.js. PR-URL: https://github.com/nodejs/node/pull/14279 Reviewed-By:
Rich Trott <rtrott@gmail.com> Reviewed-By:
Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com> Reviewed-By:
Timothy Gu <timothygu99@gmail.com> Reviewed-By:
Tobias Nießen <tniessen@tnie.de> Reviewed-By:
Gireesh Punathil <gpunathi@in.ibm.com> Reviewed-By:
Refael Ackermann <refack@gmail.com>
-
blade254353074 authored
Replace string concatenation with template string literals in test-graph.signal.js. PR-URL: https://github.com/nodejs/node/pull/14289 Reviewed-By:
Michaël Zasso <targos@protonmail.com> Reviewed-By:
Rich Trott <rtrott@gmail.com> Reviewed-By:
Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By:
Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com> Reviewed-By:
Tobias Nießen <tniessen@tnie.de> Reviewed-By:
Gireesh Punathil <gpunathi@in.ibm.com>
-
tobewhatwewant authored
In test/parallel/test-repl-persistent-history.js, replace string concatenation with a template literal. PR-URL: https://github.com/nodejs/node/pull/14288 Reviewed-By:
Michaël Zasso <targos@protonmail.com> Reviewed-By:
Rich Trott <rtrott@gmail.com> Reviewed-By:
Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By:
Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com> Reviewed-By:
Tobias Nießen <tniessen@tnie.de> Reviewed-By:
Refael Ackermann <refack@gmail.com>
-
jiangplus authored
Replace string concatenation with template literals. Updated `test/parallel/test-http-multi-line-headers.js` PR-URL: https://github.com/nodejs/node/pull/14278 Reviewed-By:
Rich Trott <rtrott@gmail.com> Reviewed-By:
David Cai <davidcai1993@yahoo.com> Reviewed-By:
Michaël Zasso <targos@protonmail.com> Reviewed-By:
Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com> Reviewed-By:
Timothy Gu <timothygu99@gmail.com> Reviewed-By:
Tobias Nießen <tniessen@tnie.de> Reviewed-By:
Gireesh Punathil <gpunathi@in.ibm.com> Reviewed-By:
Refael Ackermann <refack@gmail.com>
-
kadoufall authored
In lib/util.js, Line 1056, there is a 'depth' argument that is unused for 'process.versions[exports.inspect.custom]', so delete it. PR-URL: https://github.com/nodejs/node/pull/14267 Reviewed-By:
Rich Trott <rtrott@gmail.com> Reviewed-By:
Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By:
Tobias Nießen <tniessen@tnie.de> Reviewed-By:
Refael Ackermann <refack@gmail.com>
-
Bang Wu authored
In test/parallel/test-stream-writable-null.js, use a regular expression to validate error message in assert.throws() call. PR-URL: https://github.com/nodejs/node/pull/14268 Reviewed-By:
Rich Trott <rtrott@gmail.com> Reviewed-By:
Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com> Reviewed-By:
Timothy Gu <timothygu99@gmail.com> Reviewed-By:
Tobias Nießen <tniessen@tnie.de> Reviewed-By:
Gireesh Punathil <gpunathi@in.ibm.com> Reviewed-By:
Refael Ackermann <refack@gmail.com>
-
akira.xue authored
update test/parallel/test-vm-create-context-arg.js in line 27 to change `TypeError` to the regular expression with the `/^TypeError: sandbox must be an object$/`. PR-URL: https://github.com/nodejs/node/pull/14266 Reviewed-By:
Rich Trott <rtrott@gmail.com> Reviewed-By:
Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com>
-
Flandre authored
PR-URL: https://github.com/nodejs/node/pull/14265 Reviewed-By:
Rich Trott <rtrott@gmail.com> Reviewed-By:
Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com>
-
Song, Bintao Garfield authored
Replace the string concat at test/addons-napi/test_reference/test.js. PR-URL: https://github.com/nodejs/node/pull/14269 Reviewed-By:
Joyee Cheung <joyeec9h3@gmail.com> Reviewed-By:
Rich Trott <rtrott@gmail.com> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com>
-
Fraser Xu authored
In test-stream-writable-change-default-encoding, use a regular expression to match the complete error message. PR-URL: https://github.com/nodejs/node/pull/14264 Reviewed-By:
Rich Trott <rtrott@gmail.com> Reviewed-By:
Bryan English <bryan@bryanenglish.com>
-
Rich Trott authored
Use `.once()` rather than `.on()` for timeout listener. Add comment with URL for issue explaining the purpose of the test. (h/t refack) PR-URL: https://github.com/nodejs/node/pull/14257 Fixes: https://github.com/nodejs/node/issues/14241 Reviewed-By:
Refael Ackermann <refack@gmail.com> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com> Reviewed-By:
Yuta Hiroto <hello@about-hiroppy.com>
-
Refael Ackermann authored
This is a temporary measure until the issue is fixed. PR-URL: https://github.com/nodejs/node/pull/14246 Refs: https://github.com/nodejs/node/issues/14206 Reviewed-By:
Rich Trott <rtrott@gmail.com> Reviewed-By:
Gibson Fahnestock <gibfahn@gmail.com>
-
Refael Ackermann authored
* includes a tiny bit of refactoring in adjacent lines. * fixes 1 test and 1 benchmark that depended on PIPE being constant. PR-URL: https://github.com/nodejs/node/pull/14168 Fixes: https://github.com/nodejs/node/issues/14128 Reviewed-By:
James M Snell <jasnell@gmail.com>
-
cornholio authored
Added an option to override inspector port for workers using `settings.inspectPort` will override default port incrementing behavior. Also, using this option allows to set 0 port for the whole cluster. PR-URL: https://github.com/nodejs/node/pull/14140 Fixes: https://github.com/nodejs/node/issues/8495 Fixes: https://github.com/nodejs/node/issues/12941 Refs: https://github.com/nodejs/node/pull/9659 Refs: https://github.com/nodejs/node/pull/13761 Reviewed-By:
Refael Ackermann <refack@gmail.com> Reviewed-By:
Matteo Collina <matteo.collina@gmail.com> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com>
-
cornholio authored
10 ports for each test-case is too much. Not enough ports for new test cases, considering ~100 ports per file. PR-URL: https://github.com/nodejs/node/pull/14140 Fixes: https://github.com/nodejs/node/issues/8495 Fixes: https://github.com/nodejs/node/issues/12941 Refs: https://github.com/nodejs/node/pull/9659 Refs: https://github.com/nodejs/node/pull/13761 Reviewed-By:
Refael Ackermann <refack@gmail.com> Reviewed-By:
Matteo Collina <matteo.collina@gmail.com> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com>
-
cornholio authored
* Capitalization and punctuation. * `setupMaster` contained info about `settings` which where incomplete. PR-URL: https://github.com/nodejs/node/pull/14140 Fixes: https://github.com/nodejs/node/issues/8495 Fixes: https://github.com/nodejs/node/issues/12941 Refs: https://github.com/nodejs/node/pull/9659 Refs: https://github.com/nodejs/node/pull/13761 Reviewed-By:
Refael Ackermann <refack@gmail.com> Reviewed-By:
Matteo Collina <matteo.collina@gmail.com> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com>
-
Peter Czibik authored
PR-URL: https://github.com/nodejs/node/pull/13981 Reviewed-By:
Colin Ihrig <cjihrig@gmail.com> Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Refael Ackermann <refack@gmail.com>
-
Vse Mozhet Byt authored
This module is already required in the top scope (Line 3). PR-URL: https://github.com/nodejs/node/pull/14199 Reviewed-By:
Rich Trott <rtrott@gmail.com> Reviewed-By:
Refael Ackermann <refack@gmail.com> Reviewed-By:
Luigi Pinca <luigipinca@gmail.com> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com> Reviewed-By:
Tobias Nießen <tniessen@tnie.de> Reviewed-By:
Timothy Gu <timothygu99@gmail.com> Reviewed-By:
James M Snell <jasnell@gmail.com>
-