Joyee Cheung
3da36d0e94
lib: create primordials in every context
...
This allows us to use primordials in other per-context scripts.
PR-URL: https://github.com/nodejs/node/pull/27171
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2019-04-13 17:53:25 +08:00
Joyee Cheung
dfd7e99425
src: make a Environment-independent proxy class for NativeModuleLoader
...
This patch splits `NativeModuleLoader` into two parts - a singleton
that only relies on v8 and `node::Mutex` and a proxy class for
the singleton (`NativeModuleEnv`) that provides limited access to
the singleton as well as C++ bindings for the Node.js binary.
`NativeModuleLoader` is then no longer aware of `Environment`.
PR-URL: https://github.com/nodejs/node/pull/27160
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
2019-04-13 17:24:51 +08:00
cjihrig
9b6b567bc4
lib,src,doc: add --heapsnapshot-signal CLI flag
...
This flag allows heap snapshots to be captured without
modifying application code.
PR-URL: https://github.com/nodejs/node/pull/27133
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Sam Roberts <vieuxtech@gmail.com >
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
2019-04-12 17:16:46 -04:00
Refael Ackermann
8cf3af1486
test: optimize total Travis run time
...
* skip compilation by using cache
* split testing into two jobs
* DRY with YAML anchors
PR-URL: https://github.com/nodejs/node/pull/27182
Refs: https://github.com/nodejs/node/pull/27158
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
2019-04-12 16:39:57 -04:00
Sam Roberts
060d901f87
src: replace FromJust() with Check() when possible
...
FromJust() is often used not for its return value, but for its
side-effects. In these cases, Check() exists, and is more clear as to
the intent. From its comment:
To be used, where the actual value of the Maybe is not needed, like
Object::Set.
See: https://github.com/nodejs/node/pull/26929/files#r269256335
PR-URL: https://github.com/nodejs/node/pull/27162
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Gus Caplan <me@gus.host >
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com >
2019-04-12 12:33:37 -07:00
Richard Lau
7b0d867389
build: fix test failures not failing Travis builds
...
The exit code of the make command used to execute tests was being lost
after being piped through to grep.
PR-URL: https://github.com/nodejs/node/pull/27176
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com >
Reviewed-By: Beth Griggs <Bethany.Griggs@uk.ibm.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Minwoo Jung <minwoo@nodesource.com >
2019-04-12 14:34:28 -04:00
Refael Ackermann
25df3c10f4
build,win: put all compilation artifacts into out
...
* Add symlink from Release to out\Release for backward compat
PR-URL: https://github.com/nodejs/node/pull/27149
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
2019-04-12 14:12:40 -04:00
Rich Trott
7b854959e7
doc: revise TSC text in GOVERNANCE.md
...
Tighten up a few things to make them more concise. Clarify that changes
to the charter require board approval.
PR-URL: https://github.com/nodejs/node/pull/27169
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Beth Griggs <Bethany.Griggs@uk.ibm.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com >
2019-04-12 09:24:33 -07:00
Ruben Bridgewater
091902ae00
console: remove trace frame
...
The own function's frame was removed originally. This restors that
behavior.
Fixes: https://github.com/nodejs/node/issues/27134
PR-URL: https://github.com/nodejs/node/pull/27159
Reviewed-By: Eugene Ostroukhov <eostroukhov@google.com >
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Сковорода Никита Андреевич <chalkerx@gmail.com >
2019-04-12 19:29:24 +08:00
Michaël Zasso
908292cf1f
lib: enforce the use of Object from primordials
...
PR-URL: https://github.com/nodejs/node/pull/27146
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Gus Caplan <me@gus.host >
2019-04-12 05:38:45 +02:00
ZYSzys
9ad5106934
child_process: harden fork arguments validation
...
Ensure that the first argument `modulePath` of `fork` method
must be provided and be of type string.
PR-URL: https://github.com/nodejs/node/pull/27039
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
2019-04-12 08:54:13 +08:00
Anna Henningsen
56354d480d
build: run flaky tests in Travis
...
Skipping flaky tests in CI is an anti-pattern that should be avoided,
as we do in our ownCI. Failing flaky tests don’t need to be blockers
for a green CI result, but they should be run and reported *somehow*.
PR-URL: https://github.com/nodejs/node/pull/27158
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2019-04-11 16:06:46 -07:00
Michael Dawson
9b859f50d5
doc: add missing n-api version indicator
...
When the threadsafe functions were promoted to
version 4 from experimental we missed documenting
that. Add the version indicator for these functions
in the doc.
PR-URL: https://github.com/nodejs/node/pull/27155
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2019-04-11 17:31:19 -04:00
Refael Ackermann
abe4183d41
test: mark some known flakes
...
PR-URL: https://github.com/nodejs/node/pull/27193
Refs: https://github.com/nodejs/node/issues/20750
Refs: https://github.com/nodejs/node/issues/26610
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
2019-04-11 15:43:07 -04:00
Beth Griggs
d42456020b
2019-04-11, Version 11.14.0 (Current)
...
Notable changes:
- child_process: doc deprecate ChildProcess.\_channel (cjihrig)
[#26982 ](https://github.com/nodejs/node/pull/26982 )
- deps: update nghttp2 to 1.37.0 (gengjiawen)
[#26990 ](https://github.com/nodejs/node/pull/26990 )
- dns:
- make dns.promises enumerable (cjihrig)
[#26592 ](https://github.com/nodejs/node/pull/26592 )
- remove dns.promises experimental warning (cjihrig)
[#26592 ](https://github.com/nodejs/node/pull/26592 )
- fs: remove experimental warning for fs.promises (Anna Henningsen)
[#26581 ] (https://github.com/nodejs/node/pull/26581 )
- stream: make Symbol.asyncIterator support stable (Matteo Collina)
[#26989 ](https://github.com/nodejs/node/pull/26989 )
- worker: use copy of process.env (Anna Henningsen)
[#26544 ](https://github.com/nodejs/node/pull/26544 )
PR-URL: https://github.com/nodejs/node/pull/27163
2019-04-11 17:56:55 +01:00
Jon Kunkee
06c10cdc4c
build,win: teach GYP MSVS generator about MARMASM
...
The toolchain for ARM64 Windows includes support for assembly code, but
with a very different syntax from MASM and NASM. This change teaches
GYP how to emit the right XML tags in VCXPROJ files to support
compiling assembly files with the new tool.
PR-URL: https://github.com/nodejs/node/pull/26020
Refs: https://github.com/nodejs/node/issues/25998
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: João Reis <reis@janeasystems.com >
Reviewed-By: Refael Ackermann <refack@gmail.com >
2019-04-11 17:44:10 +01:00
gengjiawen
ee7daf76c0
src: remove redundant string initialization
...
PR-URL: https://github.com/nodejs/node/pull/27152
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
Reviewed-By: Refael Ackermann <refack@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2019-04-11 11:15:07 -04:00
gengjiawen
845a6214f8
src: use macro instead of magic number for fd
...
PR-URL: https://github.com/nodejs/node/pull/27152
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
Reviewed-By: Refael Ackermann <refack@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2019-04-11 11:15:01 -04:00
Luigi Pinca
655c90b287
net: inline maybeDestroy()
...
`maybeDestroy()` is only called from the listener of the `'end'` event.
That event is only emitted after the socket is connected (after `UV_EOF`
is read) and after `socket.readable` is set to `false`.
PR-URL: https://github.com/nodejs/node/pull/27136
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2019-04-11 07:53:30 +02:00
Anatoli Papirovski
29d0b43426
benchmark: fix http headers benchmark
...
PR-URL: https://github.com/nodejs/node/pull/27021
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 >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2019-04-11 05:41:21 +02:00
Anatoli Papirovski
47f5cc1ad1
lib: faster FreeList
...
Make FreeList faster by using Reflect.apply and not using
is_reused_symbol, but rather just checking whether any
items are present in the list prior to calling alloc.
PR-URL: https://github.com/nodejs/node/pull/27021
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 >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2019-04-11 05:40:59 +02:00
cjihrig
547576f530
src: always use diagnostic file sequence number
...
This commit attaches a sequence number to all filenames that
are automatically generated by DiagnosticFilename. This prevents
accidental overwriting of existing files.
PR-URL: https://github.com/nodejs/node/pull/27142
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
2019-04-10 20:41:39 -04:00
cjihrig
44a3acb627
report: improve signal name validation
...
PR-URL: https://github.com/nodejs/node/pull/27137
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com >
2019-04-10 20:36:10 -04:00
cjihrig
5b9e57012a
lib: add signal name validator
...
PR-URL: https://github.com/nodejs/node/pull/27137
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com >
2019-04-10 20:35:54 -04:00
Richard Lau
72f4a830d7
build: tidy up additional libraries on Windows
...
The report functionality that depended on `Dbghelp.lib` and `Psapi.lib`
are actually in `src/debug_utils.cc` and are not dependent on the
report functionality being enabled.
PR-URL: https://github.com/nodejs/node/pull/27138
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Refael Ackermann <refack@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2019-04-10 20:21:55 -04:00
Octavian Soldea
06c803d9b9
test: pass null params to napi_create_function()
...
Each one of the following arguments is checked:
napi_env env,
const char* utf8name,
napi_callback cb,
napi_value* result.
PR-URL: https://github.com/nodejs/node/pull/26998
Reviewed-By: Gabriel Schulhof <gabriel.schulhof@intel.com >
2019-04-10 16:35:22 -07:00
Marcos Casagrande
1a67c9948c
stream: remove dead code
...
Remove unreachable code. `state.ended` is always set to true
in this part of the code. The `else` clause can't be executed.
PR-URL: https://github.com/nodejs/node/pull/27125
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
2019-04-10 23:40:39 +02:00
szabolcsit
2a51ae424a
test: cover thenables when we check for promises
...
Added tests that cover the issue when assert.rejects() and
assert.doesNotReject() should not accept Thenables without
a `catch` method or any Thenable function with `catch` and
`then` methods attached.
PR-URL: https://github.com/nodejs/node/pull/24219
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
2019-04-10 23:37:41 +02:00
dnlup
d6317d0a45
module: remove usage of require('util')
...
Use `require('internal/util/debuglog').debuglog` instead of
`require('util').debuglog` in
`lib/internal/modules/esm/create_dynamic_module.js`.
PR-URL: https://github.com/nodejs/node/pull/26803
Refs: https://github.com/nodejs/node/issues/26546
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com >
2019-04-10 23:21:59 +02:00
Ruben Bridgewater
c9fece38c8
util: change inspect compact and breakLength default
...
This changes the `compact` default from `true` to `3`. That mode
changes arrays to be grouped together, it alignes multiple small
entries on a single line in similar to `compact` true but only for
the most inner three depth levels and the closing brackets are
always on the same indentation as the openeing of the object instead
of at the same line as another property.
Big strings will be naturally broken into multiple lines instead of
having one huge line that is not well readable.
The output size mainly stays the same that way while it will be
smaller in case of big arrays.
Increasing the `breakLength` to 80 adjusts for most terminals that
support at least 80 characters in a single line and improves the
general output that way. A lot of calculations use the `breakLength`
to determine the concrete behavior.
PR-URL: https://github.com/nodejs/node/pull/27109
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Minwoo Jung <minwoo@nodesource.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
2019-04-10 17:59:14 +02:00
Ruben Bridgewater
892c51f330
util: improve inspect edge cases
...
This makes sure `compact` number mode causes small proxies and map
entries to be printed on a single line.
It also fixed the line break calculation for `compact` mode when not
set to `true`. It now also adds the additional whitespace, comma and
quotes to the formula to prevent exceeding the `breakLength`.
PR-URL: https://github.com/nodejs/node/pull/27109
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Minwoo Jung <minwoo@nodesource.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
2019-04-10 17:59:12 +02:00
cjihrig
bd9109c241
lib: move DEP0021 to end of life
...
Server.listenFD() has been runtime deprecated since
Node 0.7.12. This commit moves the deprecation to
end-of-life.
PR-URL: https://github.com/nodejs/node/pull/27127
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
2019-04-10 08:25:50 -04:00
Rich Trott
41d5666aaa
doc: consolidate Collaborator status in GOVERNANCE
...
Consolidate Collaborator status material in GOVERNANCE.md.
PR-URL: https://github.com/nodejs/node/pull/27128
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Beth Griggs <Bethany.Griggs@uk.ibm.com >
Reviewed-By: Сковорода Никита Андреевич <chalkerx@gmail.com >
2019-04-09 22:02:01 -07:00
Anna Henningsen
c1e03eda07
src: use SealHandleScope for inspector tasks
...
This addresses a TODO comment that can be resolved,
now that we have V8 7.4.
PR-URL: https://github.com/nodejs/node/pull/27116
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com >
2019-04-10 05:43:47 +02:00
Richard Lau
f1ab837b0c
doc: assign missed deprecation code
...
Refs: https://github.com/nodejs/node/pull/26982
PR-URL: https://github.com/nodejs/node/pull/27164
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com >
2019-04-09 23:29:04 -04:00
Ruben Bridgewater
3a6eba3de6
test: use assert.rejects
...
This verifies that the test actually rejects at this point by using
`assert.rejects` instead of `try / catch`.
PR-URL: https://github.com/nodejs/node/pull/27123
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Yuta Hiroto <hello@hiroppy.me >
Reviewed-By: James M Snell <jasnell@gmail.com >
2019-04-10 02:52:43 +02:00
Ruben Bridgewater
3d6533ea02
test: simplify vm-module-errors test
...
Use `assert.rejects` to test error cases. This simplifies the test.
PR-URL: https://github.com/nodejs/node/pull/27123
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Yuta Hiroto <hello@hiroppy.me >
Reviewed-By: James M Snell <jasnell@gmail.com >
2019-04-10 02:52:41 +02:00
kohta ito
eb8a51a35c
child_process: use non-infinite maxBuffer defaults
...
Set the default maxBuffer size to 204,800 bytes for execSync,
execFileSync, and spawnSync.
APIs that return the child output as a string should have non-infinite
defaults for maxBuffer sizes to avoid out-of-memory error conditions. A
non-infinite default used to be the documented behaviour for all
relevant APIs, but the implemented behaviour for execSync, execFileSync
and spawnSync was to have no maxBuffer limits.
PR-URL: https://github.com/nodejs/node/pull/23027
Refs: https://github.com/nodejs/node/pull/22894
Reviewed-By: Sam Roberts <vieuxtech@gmail.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
2019-04-09 13:57:04 -07:00
cjihrig
1656cd2edb
doc: remove outdated link
...
The community maintained material hasn't been updated for
almost five years, corresponds to Node 0.11, and is no longer
accurate. This commit removes the references.
PR-URL: https://github.com/nodejs/node/pull/27126
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com >
Reviewed-By: Beth Griggs <Bethany.Griggs@uk.ibm.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2019-04-09 16:43:04 -04:00
Mykola Bilochub
643a2fa447
doc: specify return type for tty.isatty()
...
PR-URL: https://github.com/nodejs/node/pull/27154
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Denys Otrishko <shishugi@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
2019-04-09 23:06:46 +03:00
Anna Henningsen
d1413305e0
test: print child stderr in test-http-chunk-problem
...
This helps with debugging test failures.
PR-URL: https://github.com/nodejs/node/pull/27117
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Beth Griggs <Bethany.Griggs@uk.ibm.com >
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
2019-04-09 21:56:29 +02:00
Sam Roberts
bf766c1b44
src: remove unused INT_MAX constant
...
Node doesn't use it, and its not documented. Remove it.
PR-URL: https://github.com/nodejs/node/pull/27078
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2019-04-09 07:29:48 +02:00
Michael Dawson
ff89670902
n-api: reduce gc finalization stress
...
https://github.com/nodejs/node/pull/24494 fixed a crash
but resulted in increased stress on gc finalization. A leak
was reported in https://github.com/nodejs/node/issues/26667 which
we are still investigating. As part of this investigation I
realized we can optimize to reduce amount of deferred finalization.
Regardless of the root cause of the leak this should be a
good optimization. It also resolves the leak for the case being
reported in #26667 . The OP in 26667 has confirmed that he can
still recreate the original problem that 24494 fixed and that
the fix still works with this optimization
PR-URL: https://github.com/nodejs/node/pull/27085
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2019-04-09 05:45:54 +02:00
cjihrig
b925379f50
fs: warn on non-portable mkdtemp() templates
...
Refs: https://github.com/nodejs/node/issues/26435
PR-URL: https://github.com/nodejs/node/pull/26980
Reviewed-By: James M Snell <jasnell@gmail.com >
2019-04-08 21:16:56 -04:00
Ruben Bridgewater
d11c4beb4b
module: remove dead code
...
This removes a lot of code that has no functionality anymore. All
Node.js internal code calls `_resolveLookupPaths` with two arguments.
The code that validates `index.js` is not required at all as we check
for these files anyway, so it's just redundant code that should be
removed.
PR-URL: https://github.com/nodejs/node/pull/26983
Refs: https://github.com/nodejs/node/pull/25362
Reviewed-By: Jan Krems <jan.krems@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Guy Bedford <guybedford@gmail.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
2019-04-08 18:56:17 +02:00
Sam Roberts
a3f30a48c2
src: unify crypto constant setup
...
DefineCryptoConstants() sets constants from OpenSSL into
`crypto.constants`, for crypto and tls. DefineOpenSSLConstants() did
exactly the same. Unify them.
PR-URL: https://github.com/nodejs/node/pull/27077
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com >
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2019-04-08 09:46:55 -07:00
Sam Roberts
0911e88056
crypto: fix rsa key gen with non-default exponent
...
EVP_PKEY_CTX_set_rsa_keygen_pubexp() accepts ownership of the exponent
on success, so do not free it.
Fixes: https://github.com/nodejs/node/issues/27087
PR-URL: https://github.com/nodejs/node/pull/27092
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
Reviewed-By: James M Snell <jasnell@gmail.com >
2019-04-08 09:44:36 -07:00
Michael Dawson
f96a6608eb
test: fix test-worker-memory.js for large cpu #s
...
This test consistently failed on a system with a
large number of cores (~120). Cap the number of
concurrent workers so we'll stay consistently within
the "slack" allowed with respect to rss.
PR-URL: https://github.com/nodejs/node/pull/27090
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com >
2019-04-08 12:17:48 -04:00
gengjiawen
93df085386
test: fix this scope bug in test-stream2-writable.js
...
PR-URL: https://github.com/nodejs/node/pull/27111
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com >
2019-04-08 22:40:15 +08:00
Refael Ackermann
0a25ace9c3
tools: move cpplint configuration to .cpplint
...
PR-URL: https://github.com/nodejs/node/pull/27098
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com >
2019-04-08 08:30:29 -04:00