0
0
mirror of https://github.com/nodejs/node.git synced 2024-12-01 16:10:02 +01:00
Commit Graph

30105 Commits

Author SHA1 Message Date
Rich Trott
3967f865e1
tools: update to acorn@7.1.1
Update acorn to 7.1.1 in the dev dependencies for the markdown linter.

Refs: https://app.snyk.io/vuln/SNYK-JS-ACORN-559469
Signed-off-by: Rich Trott <rtrott@gmail.com>

PR-URL: https://github.com/nodejs/node/pull/32259
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
2020-03-14 14:08:45 -04:00
cjihrig
907bcad875
deps: upgrade to libuv 1.35.0
Notable changes:

- The UV_UDP_MMSG_CHUNK UDP flag has been added.
- Support has been dropped for FreeBSD < 10.
- The FreeBSD and Linux system call logic has been simplified to assume the
  presence of features covered by libuv's minimum system requirements.
- Listening on IPC pipes is no longer allowed.
- Fix iOS and Android builds.

PR-URL: https://github.com/nodejs/node/pull/32204
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2020-03-14 11:44:25 -04:00
cjihrig
ec204d86b0
test: verify that WASI errors are rethrown
This commit adds a test to verify that exceptions thrown from a
WASI application are properly caught and rethrown. This also
gets the code coverage in lib/wasi.js back to 100%.

PR-URL: https://github.com/nodejs/node/pull/32157
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
2020-03-13 18:18:15 -04:00
Anna Henningsen
605615e5f3
esm: port loader code to JS
There is no reason for this to be in C++. Using JavaScript means that
the code is more accessible to more developers, which is important
for any Node.js feature. This also simplifies the code significantly
in some areas. On the technical side, this potentially also enables
making some of the file system operations that are involved
asynchronous.

PR-URL: https://github.com/nodejs/node/pull/32201
Reviewed-By: Bradley Farias <bradley.meck@gmail.com>
Reviewed-By: Guy Bedford <guybedford@gmail.com>
2020-03-13 17:34:43 +01:00
Bradley Farias
417d847de2
util: text decoding allows SharedArrayBuffer
PR-URL: https://github.com/nodejs/node/pull/32203
Fixes: https://github.com/nodejs/node/issues/32199
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Gus Caplan <me@gus.host>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2020-03-13 17:33:41 +01:00
Matheus Marchini
75da64c058
deps: V8: cherry-pick f9257802c1c0
Original commit message:

    Fix scanner-level error reporting for hashbang

    When the file begins with a hashbang, the scanner is in a failed state
    when SkipHashbang() is called. This is usually not an issue but when
    the parser encounters an ILLEGAL token, it will reset the SyntaxError
    location because of it.

    Bug: v8:10110
    Change-Id: I1c7344bf5ad20079cff80130c991f3bff4d7e9a8
    Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1995312
    Reviewed-by: Toon Verwaest <verwaest@chromium.org>
    Commit-Queue: Toon Verwaest <verwaest@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#66038}

Refs: f9257802c1
Fixes: https://github.com/nodejs/node/issues/31284
Signed-off-by: Matheus Marchini <mmarchini@netflix.com>

PR-URL: https://github.com/nodejs/node/pull/32180
Reviewed-By: Gus Caplan <me@gus.host>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
2020-03-13 17:32:58 +01:00
Harshitha KP
16cce385c0
test: add new scenario for async-local storage
Add a new scenario of multiple clients sharing a single data
callback function managing their response data through
AsyncLocalStorage APIs

Refs: https://github.com/nodejs/node/pull/32063
Refs: https://github.com/nodejs/node/issues/32060
Refs: https://github.com/nodejs/node/issues/32062#issuecomment-593957787

Co-authored-by: Gireesh Punathil <gpunathi@in.ibm.com>

PR-URL: https://github.com/nodejs/node/pull/32082
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
2020-03-13 15:07:47 +01:00
Mateusz Krawczuk
4ffb39bdfe
http2: rename counter in mapToHeaders inner loop
This change is to prevent potential bugs - e.g., someone might
automatically use the variable `k` instead of `key`, that is used in
vicinity of this loop.
Also changed postincrement to preincrement in iteration steps. It is
probably done by the optimizer anyway, but otherwise it will save an
opcode each iteration. And it is a good practice.

PR-URL: https://github.com/nodejs/node/pull/32012
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2020-03-13 15:06:58 +01:00
Harshitha KP
4fedb702b2
test: use portable EOL
The test wanted to cut huge string into 1KB strings,
for which a new line character was inserted at appropriate
places. The value is different in Windows (10, 13).
Make it portable, by making use of os.EOL semantics

Refs: https://github.com/nodejs/node/issues/25988

PR-URL: https://github.com/nodejs/node/pull/32104
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
2020-03-13 10:51:54 +01:00
Antoine du HAMEL
a8b3d7b26b
worker: allow URL in Worker constructor
The explicit goal is to let users use `import.meta.url` to
re-load thecurrent module inside a Worker instance.

Fixes: https://github.com/nodejs/node/issues/30780
PR-URL: https://github.com/nodejs/node/pull/31664
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Gus Caplan <me@gus.host>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
2020-03-13 10:50:30 +01:00
Guy Bedford
04028aac3a
doc: update conditional exports recommendations
Co-Authored-By: Geoffrey Booth <GeoffreyBooth@users.noreply.github.com>
PR-URL: https://github.com/nodejs/node/pull/32098
Reviewed-By: Geoffrey Booth <webmaster@geoffreybooth.com>
2020-03-13 10:08:37 +01:00
Ruben Bridgewater
e322f74ce1
test: refactor and simplify test-repl-preview
Use an object to indicate which part belongs to the input and which
to the output.
On top of that this also simplifies the expected output by
automatically inserting the default repl line for previews and by
automatically checking for the correct output line length.

PR-URL: https://github.com/nodejs/node/pull/32154
Reviewed-By: Shelley Vohr <codebytere@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2020-03-13 09:58:13 +01:00
Ruben Bridgewater
9c18ff6440
repl: align preview with the actual executed code
This adds preview output for input that may not be wrapped.

PR-URL: https://github.com/nodejs/node/pull/32154
Reviewed-By: Shelley Vohr <codebytere@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2020-03-13 09:58:12 +01:00
Bartosz Sosnowski
1a844a6f3a
doc: expand fs.watch caveats
Document Windows specific fs.watch caveats.

Fixes: https://github.com/nodejs/node/issues/31702

PR-URL: https://github.com/nodejs/node/pull/32176
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Masashi Hirano <shisama07@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2020-03-13 09:55:35 +01:00
cjihrig
edb3ffb003
doc: fix os.version() Windows API
pRtlGetVersion is not a thing. This text was likely a result of
copying the variable name used in libuv. This commit updates the
documentation to reference the correct Windows API call.

PR-URL: https://github.com/nodejs/node/pull/32156
Refs: https://github.com/nodejs/node/pull/31732
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Bartosz Sosnowski <bartosz@janeasystems.com>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: James M Snell <jasnell@gmail.com>
2020-03-12 20:43:34 -04:00
ExE Boss
ba684805b6
util: use a global symbol for util.promisify.custom
Define `util.promisify.custom`
as `Symbol.for("nodejs.util.inspect.custom")`, rather than
as `Symbol("util.inspect.custom")`.

This allows custom `promisify` wrappers to easily/safely be defined
in non‑Node.js environments.

Fixes: https://github.com/nodejs/node/issues/31647

PR-URL: https://github.com/nodejs/node/pull/31672
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Gus Caplan <me@gus.host>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2020-03-12 19:51:25 +01:00
Ben Noordhuis
7f44d2ced6
build: disable libstdc++ debug containers globally
Different parts of the debug build were using differently sized
std::vectors due to `_GLIBCXX_DEBUG` sometimes being defined and
sometimes not. That ended about as well as you would expect.

Remove the flag.

Fixes: https://github.com/nodejs/node/issues/30056

PR-URL: https://github.com/nodejs/node/pull/30147
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: David Carlier <devnexen@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2020-03-12 19:49:36 +01:00
himself65
12845a8bd1
lib: use spread operator on cluster
PR-URL: https://github.com/nodejs/node/pull/32125
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
2020-03-12 16:58:08 +01:00
Harshitha KP
7fcb8da777
test: buffer.write with longer string scenario
Make sure longer strings are written up to the buffer end

Refs: https://github.com/nodejs/node/pull/32119

PR-URL: https://github.com/nodejs/node/pull/32123
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2020-03-12 16:56:35 +01:00
gengjiawen
6dca708699
src: refactor to more safe method
PR-URL: https://github.com/nodejs/node/pull/32087
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Jan Krems <jan.krems@gmail.com>
Reviewed-By: Shelley Vohr <codebytere@gmail.com>
Reviewed-By: David Carlier <devnexen@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2020-03-12 16:55:53 +01:00
Eric Bickle
d53bcea2de
test: fix test-tls-env-extra-ca-file-load
Fixes broken unit test for the NODE_EXTRA_CA_CERTS environment
variable. Unit test was exiting without evaluating any assertions
or running any tests.

Fixes: https://github.com/nodejs/node/issues/32072

PR-URL: https://github.com/nodejs/node/pull/32073
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2020-03-12 16:53:29 +01:00
himself65
b1a13b12f2
lib: change var to let/const
PR-URL: https://github.com/nodejs/node/pull/32037
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: James M Snell <jasnell@gmail.com>
2020-03-12 16:52:16 +01:00
isaacs
0ddce84272
deps: upgrade npm to 6.14.1
PR-URL: https://github.com/nodejs/node/pull/31977
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Shelley Vohr <codebytere@gmail.com>
Reviewed-By: Beth Griggs <Bethany.Griggs@uk.ibm.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
2020-03-12 16:45:28 +01:00
Michael Dawson
e45874723f doc: add Ruben to TSC
Signed-off-by: Michael Dawson <michael_dawson@ca.ibm.com>

PR-URL: https://github.com/nodejs/node/pull/32213
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Matheus Marchini <mat@mmarchini.me>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Сковорода Никита Андреевич <chalkerx@gmail.com>
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
2020-03-11 22:51:29 -07:00
Rich Trott
e6a55b4391 meta: move inactive collaborators to emeriti
I sent an email to inactive collaborators (in the previous 6 months at
the time, no commits, no PRs reviewed, and no commits landed) asking if
it was time to move to emeritus.

Some replied affirmatively and I have moved those people to emeritus.

Others replied indicating a desire to remain collaborators, and I left
them as collaborators.

The remaining folks are being moved to emeritus in this change.

Signed-off-by: Rich Trott <rtrott@gmail.com>

PR-URL: https://github.com/nodejs/node/pull/32151
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Yuta Hiroto <hello@hiroppy.me>
Reviewed-By: Myles Borins <myles.borins@gmail.com>
2020-03-11 22:05:27 -07:00
Myles Borins
3a116b6ec2
doc: add missing link for v13.11.0 changelog
Missing from release, apologies.

PR-URL: https://github.com/nodejs/node/pull/32218
Reviewed-By: Shelley Vohr <codebytere@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
2020-03-12 01:02:16 -04:00
Myles Borins
5bfbd75e47
2020-03-11 Version 13.11.0 (Current)
Notable changes:

* async_hooks:
  - add sync enterWith to ALS (Stephen Belanger)
    https://github.com/nodejs/node/pull/31945
* cli:
  - allow --jitless V8 flag in NODE\_OPTIONS (Andrew Neitsch)
    https://github.com/nodejs/node/pull/32100
* fs:
  - return first folder made by mkdir recursive (Benjamin Coe)
    https://github.com/nodejs/node/pull/31530
* n-api:
  - define release 6 (Gabriel Schulhof)
    https://github.com/nodejs/node/pull/32058
* src:
  - create a getter for kernel version (Juan José Arboleda)
    https://github.com/nodejs/node/pull/31732
* wasi:
  - add returnOnExit option (Colin Ihrig)
    https://github.com/nodejs/node/pull/32101

PR-URL: https://github.com/nodejs/node/pull/32185
2020-03-11 23:54:53 -04:00
Robert Nagy
2bfb3403ed
stream: avoid destroying writable source
User might still want to be able to use the writable side
of src. This is in the case where e.g. the Duplex input
is not directly connected to its output. Such a case could
happen when the Duplex is reading from a socket and then echos
the data back on the same socket.

PR-URL: https://github.com/nodejs/node/pull/32198
Refs: 4d93e105bf (commitcomment-37751035)
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
2020-03-11 20:57:42 -04:00
Robert Nagy
f8f20892e9
stream: avoid destroying http1 objects
http1 objects are coupled with their corresponding
res/req and cannot be treated independently as
normal streams. Add a special exception for this
in the pipeline cleanup.

Fixes: https://github.com/nodejs/node/issues/32184

PR-URL: https://github.com/nodejs/node/pull/32197
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
2020-03-11 15:03:31 -04:00
Andrey Pechkurov
51e8f28dcc
doc,test: add server.timeout property to http2 public API
Both http and https modules have server.timeout property
in public API. This commit adds documentation section and test
for server.timeout in http2 module, so it becomes consistent
with http and https.

Also improves description of callback argument in documentation
for server.setTimeout().

PR-URL: https://github.com/nodejs/node/pull/31693
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
2020-03-11 19:33:48 +01:00
Ben Noordhuis
47c2b678b7
src: DRY crypto Update() methods
Factor out the common logic into a template function.
Removes approximately six instances of copy/pasted code.

PR-URL: https://github.com/nodejs/node/pull/31767
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.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: David Carlier <devnexen@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
2020-03-11 19:30:58 +01:00
Ben Noordhuis
3b9a4035e7
crypto: optimize sign.update() and verify.update()
Use `StringBytes::InlineDecoder` to decode strings inputs in C++ land
instead of decoding them to buffers in JS land before passing them on
to the C++ layer. This is what the other update() methods already did.

PR-URL: https://github.com/nodejs/node/pull/31767
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.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: David Carlier <devnexen@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
2020-03-11 19:30:56 +01:00
Ben Noordhuis
d09e1da669
src: fix spawnSync CHECK when SIGKILL fails
We might not have sufficient privileges to signal the child process
so don't make assumptions about the return value of `uv_process_kill()`.

Example:

    node -e 'child_process.spawnSync("sudo", ["ls"], { maxBuffer: 1 })'

No test because:

1. The test needs to run as root (can't invoke sudo), and

2. The parent needs to drop privileges but can't, because
   then the child process won't have sufficient privileges.

Fixes: https://github.com/nodejs/node/issues/31747

PR-URL: https://github.com/nodejs/node/pull/31768
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.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: David Carlier <devnexen@gmail.com>
2020-03-11 19:30:08 +01:00
Juan José Arboleda
0b49e2f383
build: remove empty line on node.gyp file
PR-URL: https://github.com/nodejs/node/pull/31952
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
2020-03-11 19:29:31 +01:00
Gerhard Stoebich
c145b29987
async_hooks: avoid resource reuse by FileHandle
Wrap reused read_wrap in a unique async resource to ensure that
executionAsyncResource() is not ambiguous.

PR-URL: https://github.com/nodejs/node/pull/31972
Refs: https://github.com/nodejs/node/pull/30959
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: David Carlier <devnexen@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Stephen Belanger <admin@stephenbelanger.com>
2020-03-11 19:26:10 +01:00
Joe Pea
a220202a47
doc: include the error type in the request.resolve doc
PR-URL: https://github.com/nodejs/node/pull/32152
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
2020-03-11 17:41:54 +01:00
himself65
517b0470c7
esm: remove unused parameter on module.instantiate
PR-URL: https://github.com/nodejs/node/pull/32147
Reviewed-By: Gus Caplan <me@gus.host>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2020-03-11 17:39:47 +01:00
Nick Schonning
641eac9b0d
build: add mjs extension to lint-js
This matches what the lint-js make target passes through the CLI.

PR-URL: https://github.com/nodejs/node/pull/32145
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
2020-03-11 17:38:43 +01:00
Denys Otrishko
4b84010e5a
doc: clear up child_process command resolution
Fixes: https://github.com/nodejs/node/issues/20605
Refs: https://github.com/libuv/libuv/pull/1837

PR-URL: https://github.com/nodejs/node/pull/32091
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Bartosz Sosnowski <bartosz@janeasystems.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2020-03-11 17:36:17 +01:00
Sam Roberts
6de7b635a6
doc: clarify windows specific behaviour
It was not possible to understand which, if either, of the sentences
after the first ("Windows does not... emulation") apply specifically to
Windows.  Specifically, `kill(pid, 0)` works on Linux and Windows and I
couldn't find it documented anywhere else, but the unconditional
termination occurs only on Windows.

PR-URL: https://github.com/nodejs/node/pull/32079
Reviewed-By: Bartosz Sosnowski <bartosz@janeasystems.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2020-03-11 17:34:25 +01:00
Eric Bickle
091444a49d
src: fix missing extra ca in tls.rootCertificates
Fixes tls.rootCertificates missing certificates loaded from
NODE_EXTRA_CA_CERTS.

Fixes: https://github.com/nodejs/node/issues/32074

PR-URL: https://github.com/nodejs/node/pull/32075
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: James M Snell <jasnell@gmail.com>
2020-03-11 17:33:01 +01:00
Gerhard Stoebich
943887f5be
http, async_hooks: remove unneeded reference to wrapping resource
Remove the reference from handle to the unique/wrapping resource
ReusedHandle as there is meanwhile a strong reference for all async
resources in place via AsyncWarp::resource_.

PR-URL: https://github.com/nodejs/node/pull/32054
Refs: https://github.com/nodejs/node/pull/30959
Refs: https://github.com/nodejs/node/pull/30196
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2020-03-11 17:31:18 +01:00
Sergey Zelenov
0c545f0f72
zlib: emits 'close' event after readable 'end'
Call the close method after readable 'end' so that 'close' will be
emitted afterwards.

Fixes: https://github.com/nodejs/node/issues/32023

PR-URL: https://github.com/nodejs/node/pull/32050
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2020-03-11 17:30:22 +01:00
Anna Henningsen
c41e360de7
doc: improve Buffer documentation
Various improvements to the Buffer docs.

PR-URL: https://github.com/nodejs/node/pull/32086
Reviewed-By: James M Snell <jasnell@gmail.com>
2020-03-11 17:07:39 +01:00
himself65
ce8f5eee8e
doc: add support encoding link on string_decoder.md
PR-URL: https://github.com/nodejs/node/pull/31911
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: James M Snell <jasnell@gmail.com>
2020-03-11 17:06:13 +01:00
himself65
8790db6105
test: improve test-fs-existssync-false.js
PR-URL: https://github.com/nodejs/node/pull/31883
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2020-03-11 17:04:11 +01:00
Tobias Nießen
1b9a62cff4
crypto: make DH error messages consistent
Refs: https://github.com/nodejs/node/pull/31178
Refs: https://github.com/nodejs/node/pull/31445

PR-URL: https://github.com/nodejs/node/pull/31873
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: David Carlier <devnexen@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2020-03-11 17:02:47 +01:00
Harshitha KP
e4a72d6b60
doc: add entry for AsyncHook class
fixes: https://github.com/nodejs/node/issues/31661

PR-URL: https://github.com/nodejs/node/pull/31865
Fixes: https://github.com/nodejs/node/issues/31661
Reviewed-By: Stephen Belanger <admin@stephenbelanger.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: James M Snell <jasnell@gmail.com>
2020-03-11 17:01:08 +01:00
David Gilbertson
7baadb30bb
doc: prevent tables from shrinking page
Tables on some pages (e.g. https://nodejs.org/api/crypto.html) are
quite wide because of long content (e.g. URLs) that don't break.
With this change, cell padding is smaller on small screens, and the
table content is allowed to break.

PR-URL: https://github.com/nodejs/node/pull/31859
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: James M Snell <jasnell@gmail.com>
2020-03-11 16:59:16 +01:00
Ben Noordhuis
d2e91778d9
src: fix -Wmaybe-uninitialized compiler warning
Turn the `strategy_` method pointer into an enum-based static dispatch.

It's both safer and more secure (no chance of method pointer corruption)
and it helps GCC see that the shift and suffix tables it's complaining
about are unused in single char search mode.

Fixes the following warning:

    ../src/string_search.h:113:30: warning:
    ‘search’ may be used uninitialized in this function [-Wmaybe-uninitialized]
         return (this->*strategy_)(subject, index);

Fixes: https://github.com/nodejs/node/issues/26733
Refs: https://github.com/nodejs/node/pull/31532
Refs: https://github.com/nodejs/node/pull/31798
PR-URL: https://github.com/nodejs/node/pull/31809
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: David Carlier <devnexen@gmail.com>
Reviewed-By: Sam Roberts <vieuxtech@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: James M Snell <jasnell@gmail.com>
2020-03-11 16:57:53 +01:00