summaryrefslogtreecommitdiff
path: root/lib
AgeCommit message (Collapse)Author
2018-09-22fs: improve fs.watch ENOSPC error messageAnna Henningsen
Providing `No space left on device` is misleading in this case. Replace it with something that describes it more accurately. Refs: https://stackoverflow.com/questions/22475849/node-js-error-enospc/32600959 PR-URL: https://github.com/nodejs/node/pull/21846 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Michaël Zasso <targos@protonmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
2018-09-22http2: do not falsely emit 'aborted' on pushAnatoli Papirovski
A push stream should have its writable side closed upon receipt, to avoid emitting the 'aborted' event when the readable side is closed. PR-URL: https://github.com/nodejs/node/pull/22878 Fixes: https://github.com/nodejs/node/issues/22851 Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
2018-09-22tty: make `readStream.setRawMode()` return `this`Alexander Mills
PR-URL: https://github.com/nodejs/node/pull/22950 Fixes: https://github.com/nodejs/node/issues/22916 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Denys Otrishko <shishugi@gmail.com>
2018-09-21http2: add origin frame supportJames M Snell
PR-URL: https://github.com/nodejs/node/pull/22956 Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
2018-09-21worker,coverage: support V8 coverage generationAnna Henningsen
PR-URL: https://github.com/nodejs/node/pull/22928 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
2018-09-21tools: add bash completion for nodeDaniel Bevenius
This commit adds a --completion-bash option to node which can be sourced to provide bash code completion for node options. Usage: $ node --completion-bash > node_bash_completion $ source node_bash_completion $ node --[tab] PR-URL: https://github.com/nodejs/node/pull/20713 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Denys Otrishko <shishugi@gmail.com>
2018-09-20lib: make DOMException attributes configurable and enumerableJoyee Cheung
The `name`, `message` and `code` attributes of the DOMException interface should be enumerable and configurable. Aligning the definition with the Web allows us to use it when running the Web Platform Tests. Refs: https://heycam.github.io/webidl/#idl-DOMException PR-URL: https://github.com/nodejs/node/pull/22550 Refs: https://github.com/web-platform-tests/wpt/commit/125950d10a346482075c55d27f61a1021ca68d68 Reviewed-By: Gus Caplan <me@gus.host> Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: John-David Dalton <john.david.dalton@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
2018-09-20lib: set Symbol.toStringTag of DOMExceptionJoyee Cheung
PR-URL: https://github.com/nodejs/node/pull/22933 Refs: https://github.com/nodejs/node/pull/22550 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com> Reviewed-By: Gus Caplan <me@gus.host> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: John-David Dalton <john.david.dalton@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
2018-09-20crypto: allow promisifying generateKeyPairTobias Nießen
PR-URL: https://github.com/nodejs/node/pull/22660 Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Ujjwal Sharma <usharma1998@gmail.com> Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2018-09-20crypto: add API for key pair generationTobias Nießen
This adds support for RSA, DSA and EC key pair generation with a variety of possible output formats etc. PR-URL: https://github.com/nodejs/node/pull/22660 Fixes: https://github.com/nodejs/node/issues/15116 Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Ujjwal Sharma <usharma1998@gmail.com> Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2018-09-20lib: refactor variable declarationsZYSzys
PR-URL: https://github.com/nodejs/node/pull/22643 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
2018-09-19crypto: deprecate digest == null in PBKDF2Tobias Nießen
I assume that permitting digest === null was unintentional when digest === undefined was deprecated since their behavior was equivalent. The sha1 default for digest === null has somehow made it through refactoring of the PBKDF2 module multiple times, even though digest === undefined has been EOL for some time now. This change deprecates setting digest to null so we can fix the behavior in Node.js 12 or so. PR-URL: https://github.com/nodejs/node/pull/22861 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
2018-09-19http2: check if stream is not destroyed before sending trailersMatteo Collina
Fixes: https://github.com/nodejs/node/issues/22855 PR-URL: https://github.com/nodejs/node/pull/22896 Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
2018-09-19tty: handle setRawMode errorsNikolai Vavilov
PR-URL: https://github.com/nodejs/node/pull/22886 Refs: https://github.com/nodejs/node/issues/21773 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
2018-09-19assert: improve diff outputRuben Bridgewater
The output is now a tiny bit improved by sorting object properties when inspecting the values that are compared with each other. That reduces the overall diff for identical objects with a different property insertion order. PR-URL: https://github.com/nodejs/node/pull/22788 Refs: https://github.com/nodejs/node/issues/22763 Reviewed-By: John-David Dalton <john.david.dalton@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
2018-09-19util: add order option to `.inspect()`Ruben Bridgewater
The order option can be used to sort the inspected values in case they do not rely on their order as arrays. That way the output is stable no matter of the object property inspection order. PR-URL: https://github.com/nodejs/node/pull/22788 Refs: https://github.com/nodejs/node/issues/22763 Reviewed-By: John-David Dalton <john.david.dalton@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
2018-09-19src: deprecate global COUNTER_* and remove perfctrJames M Snell
To support Performance Counters on Windows, a number of global `COUNTER_` methods were added that are undocumented and really only intended to be used internally by Node.js. Unfortunately, the perfctr support apparently hasn't even worked for quite a while and no one has even complained. This removes the perfctr support and replaces the global functions with deprecated non-ops for now, with the intent of removing those outright in the next major release cycle. PR-URL: https://github.com/nodejs/node/pull/22485 Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: João Reis <reis@janeasystems.com>
2018-09-18src: flip Atomics.notify aliasGus Caplan
PR-URL: https://github.com/nodejs/node/pull/22844 Reviewed-By: John-David Dalton <john.david.dalton@gmail.com> Reviewed-By: Kyle Farnung <kfarnung@microsoft.com>
2018-09-18lib,doc: remove unused parameter, improve docsMaleDong
1) Remove 'callback' in 'check' function, because we don't check or use that directly. 2) Make 'digest' clearer in the documentation. PR-URL: https://github.com/nodejs/node/pull/22858 Reviewed-By: Tobias Nießen <tniessen@tnie.de> Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2018-09-18lib: move process.binding('js_stream') to internalBindingAnto Aravinth
PR-URL: https://github.com/nodejs/node/pull/22239 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Gus Caplan <me@gus.host> Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com> Reviewed-By: John-David Dalton <john.david.dalton@gmail.com> Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2018-09-18crypto: remove unused scrypt validation parameterTobias Nießen
PR-URL: https://github.com/nodejs/node/pull/22902 Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Rich Trott <rtrott@gmail.com>
2018-09-17errors: add useOriginalName to internal/errorsJoyee Cheung
This allows us to tell the type of the errors without using instanceof, which is necessary in WPT harness. PR-URL: https://github.com/nodejs/node/pull/22556 Reviewed-By: John-David Dalton <john.david.dalton@gmail.com> Reviewed-By: Gus Caplan <me@gus.host> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Refael Ackermann <refack@gmail.com>
2018-09-17inspector: enable Inspector JS API in workersEugene Ostroukhov
PR-URL: https://github.com/nodejs/node/pull/22769 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: James M Snell <jasnell@gmail.com>
2018-09-17string_decoder: support typed array or data viewBenjamin Chen
Refs: https://github.com/nodejs/node/issues/1826 PR-URL: https://github.com/nodejs/node/pull/22562 Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
2018-09-17module: fix inconsistency between load and _findPathDenys Otrishko
Files with multiple extensions are not handled by require-module system therefore if you have file 'file.foo.bar' and require('./file') it won't be found even while using require.extensions['foo.bar'] but before this commit if you have require.extensions['foo.bar'] and require.extensions['bar'] set then the latter will be called if you do require('./file') but if you remove the former the former ('foo.bar') property it will fail. This commit makes it always fail in such cases. Fixes: https://github.com/nodejs/node/issues/4778 PR-URL: https://github.com/nodejs/node/pull/22382 Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: John-David Dalton <john.david.dalton@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net>
2018-09-17tls: de-duplicate for TLSSocket methodsJon Moss
Similar approach is used for `TLSWrap`, where C++ handle methods are mapped one-to-one in JS. PR-URL: https://github.com/nodejs/node/pull/22142 Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2018-09-17util: make TextEncoder/TextDecoder globalJames M Snell
Fixes: https://github.com/nodejs/node/issues/20365 PR-URL: https://github.com/nodejs/node/pull/22281 Reviewed-By: Gus Caplan <me@gus.host> Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
2018-09-17http2: add http2stream.endAfterHeaders propertyJames M Snell
Indicates is the END_STREAM flag was set on the received HEADERS frame PR-URL: https://github.com/nodejs/node/pull/22843 Fixes: https://github.com/nodejs/node/issues/22497 Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
2018-09-17assert: add default operator to `assert.fail()`Ruben Bridgewater
This makes sure `assert.fail()` contains an operator instead of being undefined. On top of that it also fixes the `err.generatedMessage` property. Before, it was not always set correct. PR-URL: https://github.com/nodejs/node/pull/22694 Reviewed-By: John-David Dalton <john.david.dalton@gmail.com> Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
2018-09-16tools: prevent string literals in some assertionsRich Trott
String literals provided as the third argument to assert.strictEqual() or assert.deepStrictEqual() will mask the values that are causing issues. Use a lint rule to prevent such usage. PR-URL: https://github.com/nodejs/node/pull/22849 Reviewed-By: Teddy Katz <teddy.katz@gmail.com> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
2018-09-16path: remove unnecessary if statementWilliam Chargin
There is an `if`-statement in `normalizeString` (a helper function for `path.normalize`) whose `else`-branch is never taken. This patch removes it. PR-URL: https://github.com/nodejs/node/pull/22273 Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
2018-09-16src: fix `--prof-process` CLI argument handlingAnna Henningsen
Make sure that options after `--prof-process` are not treated as Node.js options. Fixes: https://github.com/nodejs/node/issues/22786 PR-URL: https://github.com/nodejs/node/pull/22790 Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Bryan English <bryan@bryanenglish.com> Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
2018-09-15child_process: move process.binding('spawn_sync') to internalBindingAnto Aravinth
PR-URL: https://github.com/nodejs/node/pull/22260 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com> Reviewed-By: John-David Dalton <john.david.dalton@gmail.com> Reviewed-By: Denys Otrishko <shishugi@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2018-09-15util: use a shared symbol for util.inspect.customchocolateboy
Define `util.inspect.custom` as `Symbol.for("nodejs.util.inspect.custom")` rather than `Symbol("util.inspect.custom")`. This allows `inspect` hooks to easily/safely be defined in non-Node.js environments. Fixes: https://github.com/nodejs/node/issues/20821 Refs: https://github.com/nodejs/node/pull/22684 PR-URL: https://github.com/nodejs/node/pull/20857 Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com> Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Michaël Zasso <targos@protonmail.com> Reviewed-By: John-David Dalton <john.david.dalton@gmail.com>
2018-09-15fs: fix promisified fs.readdir withFileTypesAnatoli Papirovski
PR-URL: https://github.com/nodejs/node/pull/22832 Reviewed-By: Bryan English <bryan@bryanenglish.com> Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: Richard Lau <riclau@uk.ibm.com> Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
2018-09-14module: add createRequireFunction methodGus Caplan
PR-URL: https://github.com/nodejs/node/pull/19360 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Jan Krems <jan.krems@gmail.com> Reviewed-By: Bradley Farias <bradley.meck@gmail.com> Reviewed-By: John-David Dalton <john.david.dalton@gmail.com>
2018-09-14lib: simplify 'processChunkSync'MaleDong
According to the real logic codes, it seems no matter whether 'nread >= kMaxLength' or not. We always close the 'self' stream first. So we can shorten it by merging them into one sample. PR-URL: https://github.com/nodejs/node/pull/22802 Reviewed-By: Tobias Nießen <tniessen@tnie.de> Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Weijia Wang <starkwang@126.com>
2018-09-13fs: ensure readdir() callback is only called oncecjihrig
This commit ensures that the readdir() callback can only be called once when the withFileTypes parameter is supplied. PR-URL: https://github.com/nodejs/node/pull/22793 Fixes: https://github.com/nodejs/node/issues/22778 Reviewed-By: Bryan English <bryan@bryanenglish.com> Reviewed-By: Anatoli Papirovski <apapirovski@mac.com> Reviewed-By: Minwoo Jung <minwoo@nodesource.com>
2018-09-13util: fix indentationLvl when exceeding max call stack sizeRuben Bridgewater
The inspection indentation level was not always reset to it's former value in case the maximum call stack size was exceeded. PR-URL: https://github.com/nodejs/node/pull/22787 Reviewed-By: James M Snell <jasnell@gmail.com>
2018-09-13lib: remove unnecessary symbolsMaleDong
Remove `(...)`, because this is a simple,sensitive expression. PR-URL: https://github.com/nodejs/node/pull/22455 Reviewed-By: Weijia Wang <starkwang@126.com> Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Gus Caplan <me@gus.host> Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com> Reviewed-By: Tobias Nießen <tniessen@tnie.de> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
2018-09-13util: limit inspection output size to 128 MBRuben Bridgewater
The maximum hard limit that `util.inspect()` could theoretically handle is the maximum string size. That is ~2 ** 28 on 32 bit systems and ~2 ** 30 on 64 bit systems. Due to the recursive algorithm a complex object could easily exceed that limit without throwing an error right away and therefore crashing the application by exceeding the heap limit. `util.inspect()` is fast enough to compute 128 MB of data below one second on an Intel(R) Core(TM) i7-5600U CPU. This hard limit allows to inspect arbitrary big objects from now on without crashing the application or blocking the event loop significantly. PR-URL: https://github.com/nodejs/node/pull/22756 Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: John-David Dalton <john.david.dalton@gmail.com>
2018-09-13crypto: assign missing deprecation codeTobias Nießen
PR-URL: https://github.com/nodejs/node/pull/22827 Refs: https://github.com/nodejs/node/pull/22747 Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
2018-09-13crypto: rename symbols to match guidelinesTobias Nießen
PR-URL: https://github.com/nodejs/node/pull/22770 Refs: https://github.com/nodejs/node/pull/22684 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Michaël Zasso <targos@protonmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
2018-09-12crypto: hide native handles from JS modulesTobias Nießen
PR-URL: https://github.com/nodejs/node/pull/22747 Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Vladimir de Turckheim <vlad2t@hotmail.com> Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com> Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
2018-09-12module: accept Windows relative pathJoão Reis
Before this change, require('.\\test.js') failed while require('./test.js') succeeded. This changes _resolveLookupPaths so that both ways are accepted on Windows. Fixes: https://github.com/nodejs/node/issues/21918 PR-URL: https://github.com/nodejs/node/pull/22186 Reviewed-By: Phillip Johnsen <johphi@gmail.com> Reviewed-By: John-David Dalton <john.david.dalton@gmail.com> Reviewed-By: Refael Ackermann <refack@gmail.com> Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: Michaël Zasso <targos@protonmail.com>
2018-09-11assert: align argument namesRuben Bridgewater
This makes sure the documented argument names and the ones thrown in errors is aligned with the actual argument name. PR-URL: https://github.com/nodejs/node/pull/22760 Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Denys Otrishko <shishugi@gmail.com> Reviewed-By: Yuta Hiroto <hello@hiroppy.me>
2018-09-11net: port isIPv6 to JSWeijia Wang
Porting isIPv6() to JS makes it 10%-250% faster in most cases and reduces some C++ code. This change also adds tests for some edge cases. PR-URL: https://github.com/nodejs/node/pull/22673 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Roman Reiss <me@silverwind.io>
2018-09-09lib: generate allowedNodeEnvironmentFlags lazilyAnna Henningsen
PR-URL: https://github.com/nodejs/node/pull/22638 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2018-09-09process: generate list of allowed env flags programmaticallyAnna Henningsen
Avoids having a separate, second source of truth on this matter. PR-URL: https://github.com/nodejs/node/pull/22638 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2018-09-07util: improve inspect performanceRuben Bridgewater
This significantly improves the inspection performance for all array types. From now on only the visible elements cause work instead of having to process all array keys no matter how many entries are visible. This also moves some code out of the main function to reduce the overall function complexity. PR-URL: https://github.com/nodejs/node/pull/22503 Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: John-David Dalton <john.david.dalton@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Refael Ackermann <refack@gmail.com>