LiviaMedeiros
ca4157ea40
fs: use kEmptyObject
...
PR-URL: https://github.com/nodejs/node/pull/43159
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
2022-07-31 09:44:47 +02:00
Morgan Roderick
835056cbcb
fs: remove unnecessary ?? operator
...
This was introduced in 57678e5581
With the `if` conditional around this statement, `options` will always
be evaluated as truthy. That means that the nullish coalescing operator
will always evaluate to the left side, make it unnecessary.
PR-URL: https://github.com/nodejs/node/pull/43073
Reviewed-By: Zeyu "Alex" Yang <himself65@outlook.com >
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
Reviewed-By: LiviaMedeiros <livia@cirno.name >
Reviewed-By: Darshan Sen <raisinten@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com >
Reviewed-By: Akhil Marsonya <akhil.marsonya27@gmail.com >
2022-07-31 09:44:47 +02:00
LiviaMedeiros
7d5e7b43f6
lib: give names to promisified methods
...
Affected functions: `fs.exists`, `readline.Interface.prototype.question`
PR-URL: https://github.com/nodejs/node/pull/43218
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Minwoo Jung <nodecorelab@gmail.com >
2022-07-31 09:44:47 +02:00
Node.js GitHub Bot
aa137caac3
deps: update corepack to 0.12.0
...
PR-URL: https://github.com/nodejs/node/pull/43748
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com >
2022-07-31 09:44:46 +02:00
Node.js GitHub Bot
04188e54f5
deps: update undici to 5.7.0
...
PR-URL: https://github.com/nodejs/node/pull/43790
Reviewed-By: Filip Skokan <panva.ip@gmail.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com >
Reviewed-By: Robert Nagy <ronagy@icloud.com >
2022-07-31 09:44:46 +02:00
npm CLI robot
09f9060f7d
deps: upgrade npm to 8.13.2
...
PR-URL: https://github.com/nodejs/node/pull/43622
Reviewed-By: Darshan Sen <raisinten@gmail.com >
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
Reviewed-By: Beth Griggs <bgriggs@redhat.com >
Reviewed-By: Ruy Adorno <ruyadorno@github.com >
2022-07-31 09:44:46 +02:00
npm CLI robot
1343615224
deps: upgrade npm to 8.13.1
...
PR-URL: https://github.com/nodejs/node/pull/43552
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com >
2022-07-31 09:44:46 +02:00
Guy Bedford
3f1ec10a66
doc: packages documentation updates for 12 EOL
...
PR-URL: https://github.com/nodejs/node/pull/43375
Backport-PR-URL: https://github.com/nodejs/node/pull/43809
Reviewed-By: Geoffrey Booth <webadmin@geoffreybooth.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
2022-07-31 09:44:46 +02:00
Antoine du Hamel
cd55e221b5
lib: use null-prototype objects for property descriptors
...
Refs: https://github.com/nodejs/node/pull/42921
PR-URL: https://github.com/nodejs/node/pull/43270
Backport-PR-URL: https://github.com/nodejs/node/pull/43804
Reviewed-By: Paolo Insogna <paolo@cowtech.it >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
Reviewed-By: Minwoo Jung <nodecorelab@gmail.com >
2022-07-31 09:44:45 +02:00
Kohei Ueno
f1c12aa6df
debugger: throw a more useful error when the frame is missing
...
PR-URL: https://github.com/nodejs/node/pull/42776
Fixes: https://github.com/nodejs/node/issues/42775
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2022-07-31 09:44:45 +02:00
Michaël Zasso
49080bc42f
deps: patch V8 to 9.4.146.26
...
Refs: https://github.com/v8/v8/compare/9.4.146.24...9.4.146.26
PR-URL: https://github.com/nodejs/node/pull/43778
Reviewed-By: Richard Lau <rlau@redhat.com >
Reviewed-By: Jiawen Geng <technicalcute@gmail.com >
2022-07-31 09:44:45 +02:00
Livia Medeiros
8e5e5a10c1
test: reduce flakiness of test-fs-read-position-validation.mjs
...
PR-URL: https://github.com/nodejs/node/pull/42999
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
2022-07-31 09:44:45 +02:00
Daniel Bevenius
e7b99e8c8d
src: add --openssl-legacy-provider option
...
This commit adds an option to Node.js named --openssl-legacy-provider
and if specified will load OpenSSL 3.0 Legacy provider when dynamically
linking Node.js v16.x with OpenSSL 3.0.
Building:
$ ./configure --shared-openssl \
--shared-openssl-libpath=/path/openssl_quic-3.0/lib64 \
--shared-openssl-includes=/path/openssl_quic-3.0/include \
--shared-openssl-libname=crypto,ssl
$ make -j8
Verify options is available:
$ ./node --help
...
--openssl-legacy-provider enable OpenSSL 3.0 legacy provider
Usage:
$ export LD_LIBRARY_PATH=/path/openssl_quic-3.0/lib64
$ export OPENSSL_MODULES=/path/openssl_quic-3.0/lib64/ossl-modules/
$ export OPENSSL_CONF=/path/openssl_quic-3.0/ssl/openssl.cnf
$ ./node --openssl-legacy-provider -p 'crypto.createHash("md4")'
Hash {
_options: undefined,
[Symbol(kHandle)]: Hash {},
[Symbol(kState)]: { [Symbol(kFinalized)]: false }
}
Fixes: https://github.com/nodejs/node/issues/40948
Refs: https://github.com/nodejs/node/issues/40455
PR-URL: https://github.com/nodejs/node/pull/40478
Backport-PR-URL: https://github.com/nodejs/node/pull/42972
Reviewed-By: Richard Lau <rlau@redhat.com >
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
2022-07-31 09:44:45 +02:00
Filip Skokan
97b2fef24a
crypto: fix webcrypto import of cfrg raw public keys
...
PR-URL: https://github.com/nodejs/node/pull/43404
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
2022-07-31 09:44:44 +02:00
Filip Skokan
a57149d14e
crypto: fix webcrypto JWK EC and OKP import crv check
...
PR-URL: https://github.com/nodejs/node/pull/43346
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
2022-07-31 09:44:44 +02:00
Filip Skokan
72a0c5c743
crypto: remove Node.js-specific webcrypto extensions
...
PR-URL: https://github.com/nodejs/node/pull/43310
Reviewed-By: James M Snell <jasnell@gmail.com >
2022-07-31 09:44:44 +02:00
hiroki osame
82dc48d36c
doc: fix specifier example in esm.md
...
PR-URL: https://github.com/nodejs/node/pull/43351
Reviewed-By: Jacob Smith <jacob@frende.me >
Reviewed-By: Geoffrey Booth <webadmin@geoffreybooth.com >
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com >
Reviewed-By: Darshan Sen <raisinten@gmail.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
2022-07-31 09:44:44 +02:00
theanarkh
d766cfaca9
net,dns: move hasObserver out of perf function
...
move the hasObserver out of startPerf and stopPerf
to avoid generating useless objects when these are no observer
PR-URL: https://github.com/nodejs/node/pull/43217
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Minwoo Jung <nodecorelab@gmail.com >
2022-07-31 09:44:43 +02:00
Feng Yu
143186145c
doc: add missing require to stream api doc
...
PR-URL: https://github.com/nodejs/node/pull/43237
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
2022-07-31 09:44:43 +02:00
Filip Skokan
2e3a69a2ba
crypto: add CFRG curves to Web Crypto API
...
PR-URL: https://github.com/nodejs/node/pull/42507
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
2022-07-31 09:44:43 +02:00
Feng Yu
8b89c7fbab
fs: export constants from fs/promises
...
PR-URL: https://github.com/nodejs/node/pull/43177
Reviewed-By: LiviaMedeiros <livia@cirno.name >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
2022-07-31 09:44:43 +02:00
Tobias Nießen
7feff014c4
doc: use serial comma in worker_threads docs
...
Refs: https://github.com/nodejs/node/pull/11321
Refs: https://github.com/nodejs/node/pull/17384
PR-URL: https://github.com/nodejs/node/pull/43220
Reviewed-By: Michael Dawson <midawson@redhat.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com >
2022-07-31 09:44:43 +02:00
theanarkh
8b0ae63316
perf_hooks: fix start_time of perf_hooks
...
PR-URL: https://github.com/nodejs/node/pull/43069
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com >
2022-07-31 09:44:42 +02:00
Shogun
9d1b4b7e29
http: add uniqueHeaders option to request and createServer
...
PR-URL: https://github.com/nodejs/node/pull/41397
Reviewed-By: Robert Nagy <ronagy@icloud.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
2022-07-31 09:44:42 +02:00
Tobias Nießen
c41bf4dc59
doc: use serial comma in assert docs
...
Refs: https://github.com/nodejs/node/pull/11321
Refs: https://github.com/nodejs/node/pull/17384
PR-URL: https://github.com/nodejs/node/pull/43154
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com >
2022-07-31 09:44:42 +02:00
Paolo Insogna
b6469537e4
doc: use consistent method symbol
...
PR-URL: https://github.com/nodejs/node/pull/42974
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com >
2022-07-31 09:44:42 +02:00
Tobias Nießen
f18867b2c0
src: fix static analysis warning and use smart ptr
...
Coverity issues a warning about `value_before_reset == ca`, where
value_before_reset is a pointer that may not be valid. While comparing
the pointer itself should still work, we should really be using smart
pointers here so that this particular check can be simplified without
running into a memory leak.
Refactor SSL_CTX_get_issuer to return a smart pointer and update the
call sites accordingly. Note that we might have to change that in the
future once we improve error handling throughout crypto/tls.
Refs: https://github.com/nodejs/node/pull/37990
PR-URL: https://github.com/nodejs/node/pull/43117
Reviewed-By: Darshan Sen <raisinten@gmail.com >
Reviewed-By: Minwoo Jung <nodecorelab@gmail.com >
2022-07-31 09:44:42 +02:00
LiviaMedeiros and Antoine du Hamel
b0d9915bc6
fs: add trailing commas
...
PR-URL: https://github.com/nodejs/node/pull/43127
Co-authored-by: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Akhil Marsonya <akhil.marsonya27@gmail.com >
2022-07-31 09:44:41 +02:00
LiviaMedeiros
464830993e
fs: make params in writing methods optional
...
This change allows passing objects as "named parameters":
- `fs.write(fd, buffer[, options], callback)`
- `fs.writeSync(fd, buffer[, options])`
- `filehandle.write(buffer[, options])`
Fixes: https://github.com/nodejs/node/issues/41666
PR-URL: https://github.com/nodejs/node/pull/42601
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Minwoo Jung <nodecorelab@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2022-07-31 09:44:41 +02:00
Tobias Nießen
a61b7fabc3
doc: use serial comma in fs docs
...
Refs: https://github.com/nodejs/node/pull/11321
Refs: https://github.com/nodejs/node/pull/17384
PR-URL: https://github.com/nodejs/node/pull/43104
Reviewed-By: LiviaMedeiros <livia@cirno.name >
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Darshan Sen <raisinten@gmail.com >
2022-07-31 09:44:41 +02:00
Himself65
54e7d0d723
typings: fix os.cpus invalid return type
...
PR-URL: https://github.com/nodejs/node/pull/43006
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Darshan Sen <raisinten@gmail.com >
2022-07-31 09:44:41 +02:00
Tobias Nießen
14c8f46091
doc: use serial comma in http docs
...
Refs: https://github.com/nodejs/node/pull/11321
Refs: https://github.com/nodejs/node/pull/17384
PR-URL: https://github.com/nodejs/node/pull/43026
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com >
2022-07-31 09:44:41 +02:00
OneNail
751f09eb28
doc: fix examples in cluster.md
...
PR-URL: https://github.com/nodejs/node/pull/42889
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com >
2022-07-31 09:44:40 +02:00
Livia Medeiros
3d7808ec3f
fs: add read(buffer[, options]) versions
...
This adds the following:
- `fs.read(fd, buffer[, options], callback)`.
- `filehandle.read(buffer[, options])`.
PR-URL: https://github.com/nodejs/node/pull/42768
Refs: https://github.com/nodejs/node/pull/42601
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
2022-07-31 09:44:40 +02:00
Antoine du Hamel
cc398a829b
doc: add node: prefix for all core modules
...
Some core modules can be loaded with or without the `node:` prefix.
Using the prefix disambiguates which specifiers refer to core modules.
This commit updates the docs to use the prefix everywhere a core module
is referenced.
PR-URL: https://github.com/nodejs/node/pull/42752
Fixes: https://github.com/nodejs/node/issues/38343
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Mestery <mestery@protonmail.com >
Reviewed-By: Darshan Sen <raisinten@gmail.com >
Reviewed-By: Akhil Marsonya <akhil.marsonya27@gmail.com >
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com >
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com >
Reviewed-By: Geoffrey Booth <webadmin@geoffreybooth.com >
Reviewed-By: Stephen Belanger <admin@stephenbelanger.com >
2022-07-31 09:44:40 +02:00
Node.js GitHub Bot
29976a356b
tools: update eslint to 8.18.0
...
PR-URL: https://github.com/nodejs/node/pull/43479
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2022-07-31 09:44:40 +02:00
Benjamin Gruenbaum
4b17a94b67
stream: port more test262 tests
...
Add some test262 tests for `every`, add some `length` checks.
Turns out properties need to be writable after all according to the
test262 tests.
PR-URL: https://github.com/nodejs/node/pull/41974
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Robert Nagy <ronagy@icloud.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
2022-07-31 09:44:39 +02:00
Mohammed Keyvanzadeh
3bc12c69a4
stream: avoid usage of deprecated APIs
...
Avoid usage of the `events.listenerCount()` method as it is
deprecated.
PR-URL: https://github.com/nodejs/node/pull/41871
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Robert Nagy <ronagy@icloud.com >
Reviewed-By: Darshan Sen <raisinten@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Mestery <mestery@protonmail.com >
Reviewed-By: Minwoo Jung <nodecorelab@gmail.com >
2022-07-31 09:44:39 +02:00
Mohammed Keyvanzadeh
4ad5a28b54
stream: refactor to use more validators
...
Use more validators where appropriate for consistency.
PR-URL: https://github.com/nodejs/node/pull/41871
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Robert Nagy <ronagy@icloud.com >
Reviewed-By: Darshan Sen <raisinten@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Mestery <mestery@protonmail.com >
Reviewed-By: Minwoo Jung <nodecorelab@gmail.com >
2022-07-31 09:44:39 +02:00
Mohammed Keyvanzadeh
545b2cd4c2
stream: use standard for loop instead of for..of
...
Use the standard `for` loop style instead of `for..of` for
consistency.
PR-URL: https://github.com/nodejs/node/pull/41871
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Robert Nagy <ronagy@icloud.com >
Reviewed-By: Darshan Sen <raisinten@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Mestery <mestery@protonmail.com >
Reviewed-By: Minwoo Jung <nodecorelab@gmail.com >
2022-07-31 09:44:39 +02:00
linkgoron
6641fda10a
stream: add iterator helper find
...
Continue iterator-helpers work by adding `find` to readable streams.
PR-URL: https://github.com/nodejs/node/pull/41849
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
2022-07-31 09:44:39 +02:00
Benjamin Gruenbaum
3ef9f8da30
stream: initial port of test262 tests
...
PR-URL: https://github.com/nodejs/node/pull/41775
Reviewed-By: Nitzan Uziely <linkgoron@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2022-07-31 09:44:38 +02:00
iMoses
f793ed550a
stream: use synchronous error validation & validate abort signal option
...
made sure top level methods aren't async/generators
so that validation errors could be caught synchronously
also added validation for the abort signal option
PR-URL: https://github.com/nodejs/node/pull/41777
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Nitzan Uziely <linkgoron@gmail.com >
2022-07-31 09:44:38 +02:00
Benjamin Gruenbaum
31cee4f914
stream: never flatten on toArray
...
PR-URL: https://github.com/nodejs/node/pull/41615
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Robert Nagy <ronagy@icloud.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
2022-07-31 09:44:38 +02:00
Livia Medeiros
2922fbb9b2
doc: clarify some default values in fs.md
...
PR-URL: https://github.com/nodejs/node/pull/42892
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Akhil Marsonya <akhil.marsonya27@gmail.com >
2022-07-31 09:44:38 +02:00
Kohei Ueno
b750ff1452
test: remove the legacy url parser function
...
PR-URL: https://github.com/nodejs/node/pull/42656
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Darshan Sen <raisinten@gmail.com >
Reviewed-By: Akhil Marsonya <akhil.marsonya27@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2022-07-31 09:44:37 +02:00
Richard Lau
01c9f5b2ae
test: only skip slow tests on Raspberry Pi devices
...
Detect the Raspberry Pi devices in the Node.js CI and only skip the
slow tests on those instead of all armv7l devices.
PR-URL: https://github.com/nodejs/node/pull/42645
Reviewed-By: Michael Dawson <midawson@redhat.com >
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
Reviewed-By: Stewart X Addison <sxa@redhat.com >
Reviewed-By: Darshan Sen <raisinten@gmail.com >
2022-07-31 09:44:37 +02:00
Niyas Sait
623dd2a70b
build: remove precompiled header and debug information for host builds
...
PR-URL: https://github.com/nodejs/node/pull/42538
Refs: https://github.com/nodejs/node/issues/42375
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
2022-07-31 09:44:37 +02:00
Livia Medeiros
637820d1e3
fs: fix write methods param validation and docs
...
The FS docs wrongfully indicated support for passing object with an own
`toString` function property to `FileHandle.prototype.appendFile`,
`FileHandle.prototype.writeFile`, `FileHandle.prototype.write`,
`fsPromises.writeFile`, and `fs.writeSync`. This commit fixes that, and
adds some test to ensure the actual behavior is aligned with the docs.
It also fixes a bug that makes the process crash if a non-buffer object
was passed to `FileHandle.prototype.write`.
Refs: https://github.com/nodejs/node/pull/34993
PR-URL: https://github.com/nodejs/node/pull/41677
Refs: https://github.com/nodejs/node/issues/41666
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2022-07-31 09:44:37 +02:00
Daeyeon Jeong
d2a615f31d
test: fix typos in test/parallel
...
This pr fixes typos in some parallel tests.
PR-URL: https://github.com/nodejs/node/pull/42502
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Qingyu Deng <i@ayase-lab.com >
Reviewed-By: Mestery <mestery@protonmail.com >
Reviewed-By: Darshan Sen <raisinten@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2022-07-31 09:44:37 +02:00