Commit Graph
36698 Commits
Author SHA1 Message Date
Tobias Nießen 3e8569cfbc src: remove ParseIP() in cares_wrap.cc
This function is only used in one place where the result argument is
never nullptr, so remove special handling of that case. Also, instead
of returning magic values 0/4/6 and then later translating those into
error/AF_INET/AF_INET6, use AF_INET/AF_INET6 directly. Lastly, inline
the function, which is simpler overall.

PR-URL: https://github.com/nodejs/node/pull/44771
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Daeyeon Jeong <daeyeon.dev@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Minwoo Jung <nodecorelab@gmail.com>
2022-10-11 14:45:29 -05:00
Rathi N Das a7666abe31 test: migrated from Promise chains to Async/Await
PR-URL: https://github.com/nodejs/node/pull/44674
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
2022-10-11 14:45:29 -05:00
Juliet Zhang 5bed2d1f46 test: change promises to async/await in test-debugger-backtrace.js
PR-URL: https://github.com/nodejs/node/pull/44677
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
2022-10-11 14:45:29 -05:00
Hope Olaidé f630881f9b test: use async/await in test-debugger-sb-before-load
PR-URL: https://github.com/nodejs/node/pull/44697
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
2022-10-11 14:45:29 -05:00
Connor Burton fada3a2ce7 test: add extra tests for basename with ext option
PR-URL: https://github.com/nodejs/node/pull/44772
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
2022-10-11 14:45:29 -05:00
cjihrig 14ec52b949 fs: don't hard code name in validatePosition()
The name of the position being validated by validatePosition()
was not being used. Instead, the string 'position' was being
used everywhere. It worked out because the only call sites were
using the name 'position' as well.

PR-URL: https://github.com/nodejs/node/pull/44767
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Daeyeon Jeong <daeyeon.dev@gmail.com>
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com>
Reviewed-By: Kohei Ueno <kohei.ueno119@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
2022-10-11 14:45:29 -05:00
cjihrig 25e6f48e4a child_process: remove lookup of undefined property
execSync() passes opts.args to checkExecSyncError(). There are
two problems:

1. opts.args appears to always be undefined.
2. Even if it was defined, checkExecSyncError() would not use
   it since the command input is guaranteed to be defined.

This commit updates the code to pass undefined instead.

PR-URL: https://github.com/nodejs/node/pull/44766
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
2022-10-11 14:45:29 -05:00
Joyee Cheung f01bb58c1e bootstrap: update comments in bootstrap/node.js
The comments in bootstrap/node.js are now out of date due to
recent changes to the bootstrap process. Update them to reflect
the current status.

PR-URL: https://github.com/nodejs/node/pull/44726
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Chengzhong Wu <legendecas@gmail.com>
2022-10-11 14:45:29 -05:00
Divya Mohan 9386c8581c test: refactor to async/await
PR-URL: https://github.com/nodejs/node/pull/44694
Reviewed-By: Stephen Belanger <admin@stephenbelanger.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
2022-10-11 14:45:29 -05:00
Geoffrey Booth 7cead5968e esm: fix duplicated test
PR-URL: https://github.com/nodejs/node/pull/44779
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
2022-10-11 14:45:29 -05:00
Madhuri 006d7f1f2a tools: refactor deprecated format in no-unescaped-regexp-dot
PR-URL: https://github.com/nodejs/node/pull/44763
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2022-10-11 14:45:29 -05:00
Rich Trott 969a12be4b doc: remove "currently" and comma splice from child_process.md
Remove redundant use of "currently" and fix a comma splice.

PR-URL: https://github.com/nodejs/node/pull/44789
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Akhil Marsonya <akhil.marsonya27@gmail.com>
Reviewed-By: Harshitha K P <harshitha014@gmail.com>
Reviewed-By: Darshan Sen <raisinten@gmail.com>
Reviewed-By: Daeyeon Jeong <daeyeon.dev@gmail.com>
2022-10-11 14:45:29 -05:00
Priya Shastri af2aa5be45 test: modify test-debugger-custom-port.js to use async-await
PR-URL: https://github.com/nodejs/node/pull/44680
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
2022-10-11 14:45:29 -05:00
Alex e10095a759 build: update timezone-update.yml
Signed-off-by: sashashura <93376818+sashashura@users.noreply.github.com>

PR-URL: https://github.com/nodejs/node/pull/44717
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Mestery <mestery@protonmail.com>
Reviewed-By: Tierney Cyren <hello@bnb.im>
Reviewed-By: Rich Trott <rtrott@gmail.com>
2022-10-11 14:45:29 -05:00
Archana Kamath e9e130925c test: update test-debugger-breakpoint-exists.js to use async/await
PR-URL: https://github.com/nodejs/node/pull/44682
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
2022-10-11 14:45:29 -05:00
poorvitusam 510365a036 test: use async/await in test-debugger-preserve-breaks
PR-URL: https://github.com/nodejs/node/pull/44696
Reviewed-By: Stephen Belanger <admin@stephenbelanger.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
2022-10-11 14:45:29 -05:00
surbhirjain 2baa3c3ce5 test: use async/await in test-debugger-profile
PR-URL: https://github.com/nodejs/node/pull/44684
Reviewed-By: Rich Trott <rtrott@gmail.com>
2022-10-11 14:45:29 -05:00
Ankita Khiratkar ffc4fadf5e test: change the promises to async/await in test-debugger-exec-scope.js
PR-URL: https://github.com/nodejs/node/pull/44685
Reviewed-By: Rich Trott <rtrott@gmail.com>
2022-10-11 14:45:29 -05:00
andiemontoyeah c6289d632a tools: update eslint-check.js to object style
Updated rule from deprecated function-style
format to object-style format.

Refs: https://eslint.org/docs/latest/developer-guide/working-with-rules
PR-URL: https://github.com/nodejs/node/pull/44706
Reviewed-By: Rich Trott <rtrott@gmail.com>
2022-10-11 14:45:28 -05:00
Rich Trott 3cb28bdde0 path: change basename() argument from ext to suffix
Closes: https://github.com/nodejs/node/issues/44773
PR-URL: https://github.com/nodejs/node/pull/44774
Fixes: https://github.com/nodejs/node/issues/44773
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Darshan Sen <raisinten@gmail.com>
Reviewed-By: Daeyeon Jeong <daeyeon.dev@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
2022-10-11 14:45:28 -05:00
Node.js GitHub Bot b06a78e85d tools: update eslint to 8.24.0
PR-URL: https://github.com/nodejs/node/pull/44778
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Darshan Sen <raisinten@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
2022-10-11 14:45:28 -05:00
Node.js GitHub Bot ce3397223b tools: update lint-md-dependencies to rollup@2.79.1
PR-URL: https://github.com/nodejs/node/pull/44776
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com>
2022-10-11 14:45:28 -05:00
RafaelGSS 5e4a2e94a1 doc: mention git node backport
PR-URL: https://github.com/nodejs/node/pull/44764
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Michael Dawson <midawson@redhat.com>
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
2022-10-11 14:45:28 -05:00
Rafael Gonzaga 618c9c8260 doc: ensure to revert node_version changes
PR-URL: https://github.com/nodejs/node/pull/44760
Reviewed-By: Ruy Adorno <ruyadorno@google.com>
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Myles Borins <myles.borins@gmail.com>
Reviewed-By: Michael Dawson <midawson@redhat.com>
Reviewed-By: Geoffrey Booth <webadmin@geoffreybooth.com>
2022-10-11 14:45:28 -05:00
Chengzhong Wu 8b8d18ab4e test: verify napi_remove_wrap with napi_delete_reference
Verify that napi_remove_wrap and napi_delete_reference should be safe
to be called consecutively on the in-out params of napi_wrap.

PR-URL: https://github.com/nodejs/node/pull/44754
Reviewed-By: Daeyeon Jeong <daeyeon.dev@gmail.com>
Reviewed-By: Michael Dawson <midawson@redhat.com>
Reviewed-By: Minwoo Jung <nodecorelab@gmail.com>
2022-10-11 14:45:28 -05:00
SergeyTsukanov 83cf979a0d fs: fix typo in mkdir example
PR-URL: https://github.com/nodejs/node/pull/44791
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Akhil Marsonya <akhil.marsonya27@gmail.com>
2022-10-11 14:45:28 -05:00
Madhulika Sharma 863361928e test: change promises to async/await
PR-URL: https://github.com/nodejs/node/pull/44683
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Rich Trott <rtrott@gmail.com>
2022-10-11 14:45:28 -05:00
Daeyeon Jeong e0fe11c189 doc: fix description for napi_get_cb_info() in n-api.md
Signed-off-by: Daeyeon Jeong <daeyeon.dev@gmail.com>
PR-URL: https://github.com/nodejs/node/pull/44761
Reviewed-By: Michael Dawson <midawson@redhat.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Chengzhong Wu <legendecas@gmail.com>
2022-10-11 14:45:28 -05:00
Ruy Adorno 895719da65 doc: fix v16.17.1 security release changelog
doc/changelogs/CHANGELOG_V16.md is missing the security release header
prior to the "Notable changes" section.

PR-URL: https://github.com/nodejs/node/pull/44759
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
Reviewed-By: Bryan English <bryan@bryanenglish.com>
Reviewed-By: Beth Griggs <bethanyngriggs@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
2022-10-11 14:45:28 -05:00
Nupur Chauhan 2e3aa39c94 test: use async/await in test-debugger-invalid-args
PR-URL: https://github.com/nodejs/node/pull/44678
Reviewed-By: Rich Trott <rtrott@gmail.com>
2022-10-11 14:45:28 -05:00
Meghana Ramesh 095cb7eba1 test: update test-debugger-low-level to use await/async
PR-URL: https://github.com/nodejs/node/pull/44688
Reviewed-By: Rich Trott <rtrott@gmail.com>
2022-10-11 14:45:28 -05:00
Tobias Nießen 2752d7c22a test: check that sysconf returns a positive value
Static analysis insists that sysconf(_SC_PAGE_SIZE) might return a
negative integer (even though it never will). This was supposed to be
handled by the existing check EXPECT_GE(page, static_cast<int>(N)).
I assume that static analysis does not consider this sufficient because
static_cast<int>(N) could be negative or zero if N exceeds INT_MAX (even
though it never will).

To resolve this (theoretical) problem, explicitly check that the return
value is positive and then cast it to a size_t.

PR-URL: https://github.com/nodejs/node/pull/44666
Reviewed-By: Darshan Sen <raisinten@gmail.com>
2022-10-11 14:45:28 -05:00
Node.js GitHub Bot c1d1ed5ae4 meta: update AUTHORS
PR-URL: https://github.com/nodejs/node/pull/44777
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Darshan Sen <raisinten@gmail.com>
2022-10-11 14:45:28 -05:00
Daeyeon JeongandAntoine du Hamel fe832a0647 doc: update the deprecation for exit code to clarify its scope
This updates the deprecation, DEP0164, to clarify its scope.

Previously, `process.exitCode` wasn't mentioned but it needs
to be applied with the same deprecation because its meaning
is the same as the `code` value and it's overridden with the
`code` value in `process.exit()`.

Signed-off-by: Daeyeon Jeong <daeyeon.dev@gmail.com>
Co-authored-by: Antoine du Hamel <duhamelantoine1995@gmail.com>
PR-URL: https://github.com/nodejs/node/pull/44714
Refs: https://github.com/nodejs/node/pull/44712
Refs: https://github.com/nodejs/node/pull/43738
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Darshan Sen <raisinten@gmail.com>
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
2022-10-11 14:45:28 -05:00
Paolo Insogna 2cee039070 http: disable chunked encoding when OBS fold is used
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
Reviewed-By: Vladimir de Turckheim <vlad2t@hotmail.com>
PR-URL: #341
CVE-ID: CVE-2022-32213, CVE-2022-32215, CVE-2022-35256
2022-10-11 14:45:28 -05:00
Michael Dawson 3872abd9a6 doc: update guidance for adding new modules
- updated based on decision to use node: prefix in
  https://github.com/nodejs/TSC/pull/1206
- updated based on agreement in TSC meeting
  on adding /promises to existing modules as per
  minutes - https://github.com/nodejs/TSC/pull/1281

Signed-off-by: Michael Dawson <mdawson@devrus.com>

PR-URL: https://github.com/nodejs/node/pull/44576
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Geoffrey Booth <webadmin@geoffreybooth.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Beth Griggs <bethanyngriggs@gmail.com>
Reviewed-By: Darshan Sen <raisinten@gmail.com>
Reviewed-By: Danielle Adams <adamzdanielle@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2022-10-11 14:45:28 -05:00
“Pooja fc1edaf0d7 test: change promise to async/await in debugger-watcher
PR-URL: https://github.com/nodejs/node/pull/44687
Reviewed-By: Franziska Hinkelmann <franziska.hinkelmann@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
2022-10-11 14:45:27 -05:00
Keeley Hammond f381a1e86a doc: add registry number for Electron 22
PR-URL: https://github.com/nodejs/node/pull/44748
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
2022-10-11 14:45:27 -05:00
Jordan Harband a6a655de35 util: increase robustness with primordials
PR-URL: https://github.com/nodejs/node/pull/41212
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
2022-10-11 14:45:27 -05:00
Filip Skokan 6758c63eba doc,crypto: cleanup removed pbkdf2 behaviours
PR-URL: https://github.com/nodejs/node/pull/44733
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Akhil Marsonya <akhil.marsonya27@gmail.com>
2022-10-11 14:45:27 -05:00
Evan Lucas 2e87cdd1e6 benchmark: fix startup benchmark
This allows the misc/startup benchmark to run again
after the renaming of the C++ `native_module` to `builtins`

PR-URL: https://github.com/nodejs/node/pull/44727
Refs: https://github.com/nodejs/node/pull/44135
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Daeyeon Jeong <daeyeon.dev@gmail.com>
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Darshan Sen <raisinten@gmail.com>
2022-10-11 14:45:27 -05:00
Lucas Santos 8d3cb6c08a doc: include code examples for webstreams consumers
Add missing examples for webstreams consumers

Doc URL: https://nodejs.org/api/webstreams.html#streamconsumerstextstream

PR-URL: https://github.com/nodejs/node/pull/44387
Reviewed-By: Erick Wendel <erick.workspace@gmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Daijiro Wachi <daijiro.wachi@gmail.com>
2022-10-11 14:45:27 -05:00
Santiago Gimeno 916f2c5783 src: avoid using v8 on Isolate termination
Fix multiple instances of those uncovered while running the tests on
debug builds.

Fixes: https://github.com/nodejs/node-v8/issues/227
PR-URL: https://github.com/nodejs/node/pull/44669
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Darshan Sen <raisinten@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
2022-10-11 14:45:27 -05:00
chexiongsheng 1308e68a16 gyp: libnode for ios app embedding
PR-URL: https://github.com/nodejs/node/pull/44210
Reviewed-By: Jiawen Geng <technicalcute@gmail.com>
2022-10-11 14:45:27 -05:00
RafaelGSS 9e83c00e0b doc: mention where to push security commits
PR-URL: https://github.com/nodejs/node/pull/44691
Reviewed-By: Danielle Adams <adamzdanielle@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Myles Borins <myles.borins@gmail.com>
2022-10-11 14:45:27 -05:00
Connor Burton bc9f8d24ce doc: remove extra space on threadpool usage
PR-URL: https://github.com/nodejs/node/pull/44734
Reviewed-By: Darshan Sen <raisinten@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2022-10-11 14:45:27 -05:00
Jacob Smith 42a91e36dd esm,loader: tidy ESMLoader internals
PR-URL: https://github.com/nodejs/node/pull/44701
Reviewed-By: Geoffrey Booth <webadmin@geoffreybooth.com>
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
2022-10-11 14:45:27 -05:00
Rich Trott fe91711ed5 meta: add mailmap entry for dnlup
This updates dnlup's name to their preferred email per their last pull
request.

This will also prevent duplicate entries for dnlup when the
update-authors job runs.

It also moves one unrelated line in .mailmap so that all lines are
sorted in lexical order.

PR-URL: https://github.com/nodejs/node/pull/44716
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Daeyeon Jeong <daeyeon.dev@gmail.com>
Reviewed-By: Darshan Sen <raisinten@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
2022-10-11 14:45:27 -05:00
1079c8099d tools: add update-llhttp.sh
PR-URL: https://github.com/nodejs/node/pull/44652
Reviewed-By: Michael Dawson <midawson@redhat.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Co-authored-by: Antoine du Hamel <duhamelantoine1995@gmail.com>
Co-authored-by: Tobias Nießen <tniessen@tnie.de>
Co-authored-by: Luigi Pinca <luigipinca@gmail.com>
2022-10-11 14:45:27 -05:00
Node.js GitHub Bot b9deb1e84d meta: update AUTHORS
PR-URL: https://github.com/nodejs/node/pull/44705
Reviewed-By: Moshe Atlow <moshe@atlow.co.il>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Daeyeon Jeong <daeyeon.dev@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
2022-10-11 14:45:27 -05:00