cjihrig
1ecc03eccd
doc,lib,src,test: rename --test-coverage
...
Add experimental to the name as requested during review.
PR-URL: https://github.com/nodejs/node/pull/46017
Reviewed-By: Moshe Atlow <moshe@atlow.co.il >
Reviewed-By: Geoffrey Booth <webadmin@geoffreybooth.com >
2023-01-08 16:10:00 -05:00
cjihrig
8c95cb012b
test_runner: add initial code coverage support
...
This commit adds code coverage functionality to the node:test
module. When node:test is used in conjunction with the new
--test-coverage CLI flag, a coverage report is created when
the test runner finishes. The coverage summary is forwarded to
any test runner reporters so that the display can be customized
as desired. This new functionality is compatible with the
existing NODE_V8_COVERAGE environment variable as well.
There are still several limitations, which will be addressed in
subsequent pull requests:
- Coverage is only reported for a single process. It is possible
to merge coverage reports together. Once this is done, the
--test flag will be supported as well.
- Source maps are not currently supported.
- Excluding specific files or directories from the coverage
report is not currently supported. Node core modules and
node_modules/ are excluded though.
PR-URL: https://github.com/nodejs/node/pull/46017
Reviewed-By: Moshe Atlow <moshe@atlow.co.il >
Reviewed-By: Geoffrey Booth <webadmin@geoffreybooth.com >
2023-01-08 16:09:41 -05:00
Moshe Atlow
11e7858553
assert: remove assert.snapshot
...
PR-URL: https://github.com/nodejs/node/pull/46112
Reviewed-By: Geoffrey Booth <webadmin@geoffreybooth.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
2023-01-07 20:24:24 +00:00
Filip Skokan
021f72618c
crypto: return correct bit length in KeyObject's asymmetricKeyDetails
...
PR-URL: https://github.com/nodejs/node/pull/46106
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
2023-01-07 13:12:13 +00:00
Vadim
21c70ac84a
src: fix typo in node_snapshotable.cc
...
ImmeidateInfo -> ImmediateInfo
PR-URL: https://github.com/nodejs/node/pull/46103
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
Reviewed-By: Darshan Sen <raisinten@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2023-01-07 09:56:43 +00:00
theanarkh
9e86c492ec
src: keep PipeWrap::Open function consistent with TCPWrap
...
PR-URL: https://github.com/nodejs/node/pull/46064
Reviewed-By: Darshan Sen <raisinten@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
2023-01-06 23:49:15 +00:00
Chengzhong Wu
198d2037f1
node-api: disambiguate napi_add_finalizer
...
napi_add_finalizer doesn't support any operations related to
napi_wrap. Remove the ambiguous statements in the doc about
napi_wrap and avoid reusing the v8impl::Wrap call.
PR-URL: https://github.com/nodejs/node/pull/45401
Reviewed-By: Michael Dawson <midawson@redhat.com >
2023-01-04 18:56:12 +08:00
Darshan Sen
e35e893d26
src: speed up process.getActiveResourcesInfo()
...
This change reduces the number of calls that were crossing the JS-C++
boundary to 1 and also removes the need for calling Array::New()
multiple times internally and ArrayPrototypeConcat-ing the results
later on, thus improving performance.
Refs: https://github.com/nodejs/node/pull/44445#pullrequestreview-1220052837
Signed-off-by: Darshan Sen <raisinten@gmail.com >
PR-URL: https://github.com/nodejs/node/pull/46014
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
2023-01-03 10:36:25 +00:00
Ben Noordhuis
8ec1b0870b
crypto: ensure exported webcrypto EC keys use uncompressed point format
...
The WebCrypto spec apparently mandates that EC keys must be exported in
uncompressed point format. This commit makes it so.
Fixes: https://github.com/nodejs/node/issues/45859
PR-URL: https://github.com/nodejs/node/pull/46021
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
Reviewed-By: Filip Skokan <panva.ip@gmail.com >
2023-01-01 19:48:51 +01:00
Vadim
4830a6cf2a
src: fix typo in node_file.cc
...
`undefinec` -> `undefined`
PR-URL: https://github.com/nodejs/node/pull/45998
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Harshitha K P <harshitha014@gmail.com >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
2022-12-29 00:13:45 +01:00
Santiago Gimeno
34af1f69b9
src: fix crash on OnStreamRead on Windows
...
On Windows it's perfectly possible that the `uv_tcp_t` `read_cb` is
called with an error and a null `uv_buf_t` if it corresponds to a
`UV_HANDLE_ZERO_READ` read. Handle this case without crashing.
Fixes: https://github.com/nodejs/node/issues/40764
PR-URL: https://github.com/nodejs/node/pull/45878
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2022-12-28 11:59:51 +00:00
legendecas
8dfd905ba3
src: add worker per-isolate binding initialization
...
Create worker binding templates in the per-isolate initialization.
PR-URL: https://github.com/nodejs/node/pull/45547
Refs: https://github.com/nodejs/node/issues/42528
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2022-12-28 11:55:24 +08:00
legendecas
43105220a7
src: define per-isolate internal bindings registration callback
...
Bindings that need to be loaded in distinct contexts of node::Realm in
the same node::Environment instance needs to share the per-isolate
templates.
Add a new binding registration callback, which is called with
per-IsolateData. This allows bindings to define templates and
share them across realms eagerly, and avoid accidental modification on
the templates when the per-context callback is called multiple times.
This also tracks loaded bindings and built-in modules with node::Realm.
PR-URL: https://github.com/nodejs/node/pull/45547
Refs: https://github.com/nodejs/node/issues/42528
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2022-12-28 11:55:14 +08:00
ywave620
8438f3b73b
process,worker: ensure code after exit() effectless
...
Cope with the delay(to the next function call) of
v8::Isolate::TerminateExecution()
PR-URL: https://github.com/nodejs/node/pull/45620
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Minwoo Jung <nodecorelab@gmail.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
2022-12-25 09:54:12 +00:00
Yagiz Nizipli
d5a08c7e11
buffer: add buffer.isUtf8 for utf8 validation
...
PR-URL: https://github.com/nodejs/node/pull/45947
Reviewed-By: Robert Nagy <ronagy@icloud.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com >
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
2022-12-25 02:32:05 +00:00
Paolo Insogna
05975d1fb1
net: add autoSelectFamily global getter and setter
...
PR-URL: https://github.com/nodejs/node/pull/45777
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
2022-12-24 14:44:11 +00:00
Anna Henningsen
43e09af8e6
src: fix creating Isolates from addons
...
daae938f32 broke addons which create their own `Isolate`
instances, because enabling the shared-readonly-heap feature
of V8 requires all snapshots used for different `Isolate`s to
be identical. Usage of addons that do this has probably
decreased quite a bit since Worker threads were introduced
in Node.js, but it’s still a valid use case, and in any case
the breakage was probably not intentional (although the referenced
commit did require test changes because of this issue).
This commit addresses this issue partially by caching the
V8 snapshot parameters and ignoring ones passed in from users
in `NewIsolate()` when this feature is enabled, and makes
the `NodeMainInstance` snapshot-based isolate creation
also re-use this code.
PR-URL: https://github.com/nodejs/node/pull/45885
Reviewed-By: James M Snell <jasnell@gmail.com >
2022-12-23 17:06:05 +00:00
Yagiz Nizipli
2ef13b8fb6
util: add fast path for text-decoder fatal flag
...
PR-URL: https://github.com/nodejs/node/pull/45803
Reviewed-By: Robert Nagy <ronagy@icloud.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Michael Dawson <midawson@redhat.com >
2022-12-22 20:22:28 +00:00
Anna Henningsen
1773b2ada4
src: use string_view for FastStringKey implementation
...
PR-URL: https://github.com/nodejs/node/pull/45914
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
2022-12-21 22:48:46 +00:00
cjihrig
288c421f36
os: add availableParallelism()
...
This commit exposes uv_available_parallelism() as an alternative
to cpus().length. uv_available_parallelism() is inspired by
Rust's available_parallelism().
PR-URL: https://github.com/nodejs/node/pull/45895
Reviewed-By: Moshe Atlow <moshe@atlow.co.il >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
2022-12-21 16:53:24 -05:00
Anna Henningsen
01323d50c4
src: use CreateEnvironment instead of inlining its code where possible
...
We had a number of places in which we created an `Environment` instance
by performing each step in `CreateEnvironment` manually. Instead,
just call the function itself.
PR-URL: https://github.com/nodejs/node/pull/45886
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
2022-12-21 16:21:48 +00:00
Ben Noordhuis
51246139e7
src: fix UB in overflow checks
...
Refs: https://github.com/nodejs/node/issues/45868
PR-URL: https://github.com/nodejs/node/pull/45882
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2022-12-20 22:11:53 +00:00
A. Wilcox
95200ba645
src: check size of args before using for exec_path
...
If we are in an artifically created Environment that has no args set,
and uv_exepath returns an error (for instance, if /proc is not mounted
on a Linux system), then we crash with a nullptr deref attempting to
use argv[0].
Fixes: https://github.com/nodejs/node/issues/45901
PR-URL: https://github.com/nodejs/node/pull/45902
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2022-12-20 21:55:19 +00:00
legendecas
f14fa1bbca
node-api: generalize finalizer second pass callback
...
Generalize the finalizer's second pass callback to make it
cancellable and simplify the code around the second pass callback.
With this change, it is determined that Reference::Finalize or
RefBase::Finalize are called once, either from the env's shutdown,
or from the env's second pass callback.
All existing node-api js tests should pass without a touch. The
js_native_api cctest is no longer applicable with this change,
just removing it.
PR-URL: https://github.com/nodejs/node/pull/44141
Refs: https://github.com/nodejs/node/issues/44071
Reviewed-By: Michael Dawson <midawson@redhat.com >
2022-12-20 01:44:42 +08:00
Moshe Atlow
a1b27b25bb
test_runner: add reporters
...
PR-URL: https://github.com/nodejs/node/pull/45712
Fixes: https://github.com/nodejs/node/issues/45648
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
2022-12-19 17:35:57 +00:00
Ben Noordhuis
273d869955
src: fix tls certificate root store data race
...
OpenSSL internally synchronizes access to the X509_STORE. Creation of
the global root store in Node was not properly synchronized, however,
introducing the possibility of data races when multiple threads try to
create it concurrently.
This commit coincidentally removes the last call to the thread-unsafe
ERR_error_string() function.
Fixes: https://github.com/nodejs/node/issues/45743
PR-URL: https://github.com/nodejs/node/pull/45767
Reviewed-By: Anna Henningsen <anna@addaleax.net >
2022-12-19 12:29:19 +00:00
Debadree Chatterjee
9d1d94819f
src: add undici and acorn to process.versions
...
Fixes: https://github.com/nodejs/node/issues/45260
Refs: https://github.com/nodejs/node/pull/45599
Refs: https://github.com/nodejs/node/issues/45260
PR-URL: https://github.com/nodejs/node/pull/45621
Reviewed-By: James M Snell <jasnell@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-12-18 16:49:08 +01:00
Joyee Cheung
579235747e
bootstrap: support module_wrap binding in snapshot
...
PR-URL: https://github.com/nodejs/node/pull/45849
Reviewed-By: Geoffrey Booth <webadmin@geoffreybooth.com >
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
2022-12-16 12:43:49 +01:00
Filip Skokan
0665fa4009
doc: remove last example use of require('crypto').webcrypto
...
PR-URL: https://github.com/nodejs/node/pull/45819
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Akhil Marsonya <akhil.marsonya27@gmail.com >
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
2022-12-13 19:12:02 +01:00
David Benjamin
8b89d4d421
tls: don't treat fatal TLS alerts as EOF
...
SSL_RECEIVED_SHUTDOWN means not just close_notify or fatal alert. From
what I can tell, this was just a mistake? OnStreamRead's comment
suggests eof_ was intended to be for close_notify.
This fixes a bug in TLSSocket error reporting that seems to have made it
into existing tests. If we receive a fatal alert, EmitRead(UV_EOF)
would, via onConnectEnd in _tls_wrap.js, synthesize an ECONNRESET before
the alert itself is surfaced. As a result, TLS alerts received during
the handshake are misreported by Node.
See the tests that had to be updated as part of this.
PR-URL: https://github.com/nodejs/node/pull/44563
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2022-12-12 19:45:58 +00:00
David Benjamin
7c745142a4
tls: fix re-entrancy issue with TLS close_notify
...
Like errno, OpenSSL's API requires SSL_get_error and error queue be
checked immediately after the failing operation, otherwise the error
queue or SSL object may have changed state and no longer report
information about the operation the caller wanted.
TLSWrap almost heeds this rule, except in TLSWrap::ClearOut. If SSL_read
picks up a closing alert (detected by checking SSL_get_shutdown), Node
calls out to JS with EmitRead(UV_EOF) and only afterwards proceeds to
dispatch on the error. But, by this point, Node has already re-entered
JS, which may change the error.
In particular, I've observed that, on close_notify, JS seems to
sometimes call back into TLSWrap::DoShutdown, calling SSL_shutdown. (I
think this comes from onStreamRead in stream_base_commons.js?)
Instead, SSL_get_error and the error queue should be sampled earlier.
Back in #1661 , Node needed to account for GetSSLError being called after
ssl_ was destroyed. This was the real cause. With this fixed, there's no
need to account for this. (Any case where ssl_ may be destroyed before
SSL_get_error is a case where ssl_ or the error queue could change
state, so it's a bug either way.)
This is the first of two fixes in error-handling here. The
EmitRead(UV_EOF) seems to additionally swallow fatal alerts from the
peer. Some of the ECONNRESET expectations in the tests aren't actually
correct. The next commit will fix this as well.
PR-URL: https://github.com/nodejs/node/pull/44563
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2022-12-12 19:45:57 +00:00
Debadree Chatterjee
79a977ae31
watch: add CLI flag to preserve output
...
Fixes: https://github.com/nodejs/node/issues/45713
PR-URL: https://github.com/nodejs/node/pull/45717
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Moshe Atlow <moshe@atlow.co.il >
2022-12-11 23:23:11 +01:00
Jithil P Ponnan
5108cf2df4
src: add uvwasi version
...
PR-URL: https://github.com/nodejs/node/pull/45639
Refs: https://github.com/nodejs/node/issues/45260
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: theanarkh <theratliter@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2022-12-11 19:24:28 +00:00
Anna Henningsen
d498bd9a8c
src: simplify NodeBIO::GetMethod initialization
...
Make its initialization self-contained to avoid unnecessarily
breaking encapsulation.
PR-URL: https://github.com/nodejs/node/pull/45799
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com >
Reviewed-By: Minwoo Jung <nodecorelab@gmail.com >
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
2022-12-11 14:45:07 +00:00
Ben Noordhuis
8273320f9f
src: make structuredClone work for process.env
...
Fixes: https://github.com/nodejs/node/issues/45380
PR-URL: https://github.com/nodejs/node/pull/45698
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
2022-12-11 12:54:15 +00:00
Anna Henningsen
94d23f5ec0
src: mark generated snapshot_data as const
...
This renders the mutex protecting it unnecessary, since mutexes
only need to protect concurrent accesses to mutable data.
PR-URL: https://github.com/nodejs/node/pull/45786
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: Minwoo Jung <nodecorelab@gmail.com >
2022-12-10 17:16:24 +00:00
Ben Noordhuis
3ff724dd23
tls: remove trustcor root ca certificates
...
Follow what Ubuntu did and simply remove the CA certificates
altogether.
Fixes: https://github.com/nodejs/node/issues/45762
Refs: https://ubuntu.com/security/notices/USN-5761-2
PR-URL: https://github.com/nodejs/node/pull/45776
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Richard Lau <rlau@redhat.com >
2022-12-10 15:57:01 +00:00
Marco Ippolito
5fe0795041
crypto: fix CipherBase Update int32 overflow
...
PR-URL: https://github.com/nodejs/node/pull/45769
Fixes: https://github.com/nodejs/node/issues/45757
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Filip Skokan <panva.ip@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Paolo Insogna <paolo@cowtech.it >
2022-12-09 11:24:51 +00:00
snek
b3bf07e019
wasi: fast calls
...
PR-URL: https://github.com/nodejs/node/pull/43697
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2022-12-08 04:22:37 +00:00
Michael Dawson
22c645d411
src: cleanup on disambiguating native modules
...
Found while backporting
https://github.com/nodejs/node/pull/45663
Fixup one rename missed
Signed-off-by: Michael Dawson <mdawson@devrus.com >
PR-URL: https://github.com/nodejs/node/pull/45665
Reviewed-By: Daeyeon Jeong <daeyeon.dev@gmail.com >
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2022-12-02 16:34:09 -05:00
Deokjin Kim
1750a94ec1
src: use enum class instead of enum in node_i18n
...
"enum class" has more advantages than "enum" because
it's strongly typed and scoped.
Refs: https://isocpp.org/wiki/faq/cpp11-language-types#enum-class
PR-URL: https://github.com/nodejs/node/pull/45646
Reviewed-By: Darshan Sen <raisinten@gmail.com >
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
Reviewed-By: Minwoo Jung <nodecorelab@gmail.com >
2022-11-30 01:23:37 +00:00
theanarkh
d579bc16b3
diagnostics_channel: fix diagnostics channel memory leak
...
PR-URL: https://github.com/nodejs/node/pull/45633
Reviewed-By: Stephen Belanger <admin@stephenbelanger.com >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Minwoo Jung <nodecorelab@gmail.com >
Reviewed-By: Darshan Sen <raisinten@gmail.com >
2022-11-29 10:58:43 +00:00
legendecas
71ff89f929
src: rename internal module declaration as internal bindings
...
This is a continuation of the name reification on the internal bindings.
Renames NODE_MODULE_CONTEXT_AWARE_INTERNAL and
NODE_MODULE_EXTERNAL_REFERENCE to NODE_BINDING_CONTEXT_AWARE_INTERNAL
and NODE_BINDING_EXTERNAL_REFERENCE respectively.
PR-URL: https://github.com/nodejs/node/pull/45551
Refs: https://github.com/nodejs/node/issues/44036
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com >
Reviewed-By: Daeyeon Jeong <daeyeon.dev@gmail.com >
Reviewed-By: Jacob Smith <jacob@frende.me >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
2022-11-29 00:23:08 +08:00
Michaël Zasso
a6242772ec
src: fix ArrayBuffer::Detach deprecation
...
PR-URL: https://github.com/nodejs/node/pull/45579
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2022-11-27 17:27:21 +00:00
Yagiz Nizipli
dd5c39a808
src: update NODE_MODULE_VERSION to 112
...
Major V8 updates are usually API/ABI incompatible with previous
versions. This commit adapts NODE_MODULE_VERSION for V8 10.9.
Refs: https://github.com/nodejs/CTC/blob/master/meetings/2016-09-28.md
PR-URL: https://github.com/nodejs/node/pull/45579
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2022-11-27 17:27:15 +00:00
Yagiz Nizipli
60810f0da6
buffer: make decodeUTF8 params loose
...
PR-URL: https://github.com/nodejs/node/pull/45610
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Darshan Sen <raisinten@gmail.com >
2022-11-27 06:48:51 +00:00
Yagiz Nizipli
9a8d82b99f
src: add internal isArrayBufferDetached
...
PR-URL: https://github.com/nodejs/node/pull/45568
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: LiviaMedeiros <livia@cirno.name >
2022-11-27 03:14:57 +00:00
Michael Dawson
a01dbf179e
src: address coverity warning in node_file.cc
...
Address coverity warning that looks like
it identifies a potential crash due to using
a value after it's been passed into std::move
Signed-off-by: Michael Dawson <mdawson@devrus.com >
PR-URL: https://github.com/nodejs/node/pull/45565
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com >
Reviewed-By: Daeyeon Jeong <daeyeon.dev@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Minwoo Jung <nodecorelab@gmail.com >
2022-11-24 09:22:16 -05:00
Michael Dawson
0bbef56760
node-api: address coverity warning
...
- address coverity unitialized variable warning
Signed-off-by: Michael Dawson <mdawson@devrus.com >
PR-URL: https://github.com/nodejs/node/pull/45563
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Richard Lau <rlau@redhat.com >
Reviewed-By: Daeyeon Jeong <daeyeon.dev@gmail.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2022-11-24 09:21:03 -05:00
Daeyeon Jeong
be9cd3ecb0
src,lib: group properties used as constants from util binding
...
Properties used as constants in `util` internal binding are
scattered. This suggests using an object holding all of them
for better maintenance.
Signed-off-by: Daeyeon Jeong <daeyeon.dev@gmail.com >
PR-URL: https://github.com/nodejs/node/pull/45539
Reviewed-By: Darshan Sen <raisinten@gmail.com >
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
Reviewed-By: Minwoo Jung <nodecorelab@gmail.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
2022-11-24 02:09:29 +00:00