Anatoli Papirovski
4f2000f9fe
timers: call destroy on interval error
...
When an interval callback throws an error, the destroy
hook is never called due to a faulty if condition.
PR-URL: https://github.com/nodejs/node/pull/20001
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com >
2018-04-17 16:05:11 +02:00
Anatoli Papirovski
734eb17e5d
timers: fix subsequent enroll calls not working
...
A bug was introduced in #17704 which meant that subsequent
calls to enroll would unset the new _idleTimeout and the
enrolled object could never again function as a timer.
PR-URL: https://github.com/nodejs/node/pull/19936
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com >
2018-04-17 16:01:39 +02:00
davidmarkclements
31d6cec60e
errors: alter ERR_INVALID_CURSOR_POS
...
Changes the base instance for ERR_INVALID_CURSOR_POS from Error to
TypeError as a more accurate representation of the error.
PR-URL: https://github.com/nodejs/node/pull/19960
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
Reviewed-By: Khaidi Chu <i@2333.moe >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
2018-04-17 14:30:08 +02:00
Anatoli Papirovski
15e136d9c5
test: fix http-agent-destroyed-socket cb not firing
...
A whole part of the test-http-agent-destroyed-socket test
was not running as the semantics of http events changed
slightly and were no longer triggering the expected event.
Instead listen to the same event on the socket to verify
that the code being tested is still working as expected.
PR-URL: https://github.com/nodejs/node/pull/20006
Fixes: https://github.com/nodejs/node/issues/8613
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
2018-04-17 14:20:20 +02:00
Vse Mozhet Byt
5eb9f3c91c
doc: prevent one more false-positive linkification
...
PR-URL: https://github.com/nodejs/node/pull/20087
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com >
2018-04-17 04:58:18 +03:00
Vse Mozhet Byt
7dd6d864cb
doc: fix suspicious heading emphasis in n-api.md
...
PR-URL: https://github.com/nodejs/node/pull/20086
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Kyle Farnung <kfarnung@microsoft.com >
2018-04-17 04:51:55 +03:00
Myles Borins
daed72f224
deps: patch V8 to 6.6.346.24
...
PR-URL: https://github.com/nodejs/node/pull/19995
Refs: https://github.com/v8/v8/compare/6.6.346.23...6.6.346.24
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Yang Guo <yangguo@chromium.org >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2018-04-16 15:59:39 -04:00
Ujjwal Sharma
fb2d9df757
doc: add ryzokuken to collaborators
...
PR-URL: https://github.com/nodejs/node/pull/20081
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com >
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
2018-04-16 23:47:59 +05:30
James M Snell
237aa7e9ae
http2: refactor how trailers are done
...
Rather than an option, introduce a method and an event...
```js
server.on('stream', (stream) => {
stream.respond(undefined, { waitForTrailers: true });
stream.on('wantTrailers', () => {
stream.sendTrailers({ abc: 'xyz'});
});
stream.end('hello world');
});
```
This is a breaking change in the API such that the prior
`options.getTrailers` is no longer supported at all.
Ordinarily this would be semver-major and require a
deprecation but the http2 stuff is still experimental.
PR-URL: https://github.com/nodejs/node/pull/19959
Reviewed-By: Yuta Hiroto <hello@hiroppy.me >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
2018-04-16 09:53:32 -07:00
Vse Mozhet Byt
2e76b175ed
doc: fix two sorting nits in fs.md
...
PR-URL: https://github.com/nodejs/node/pull/20078
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2018-04-16 19:20:17 +03:00
Vse Mozhet Byt
addc04be0b
doc: add tools/doc/README link in doc/STYLE_GUIDE
...
PR-URL: https://github.com/nodejs/node/pull/20071
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
2018-04-16 19:16:10 +03:00
Ruben Bridgewater
f413f56c36
util: fix inspect performance bug
...
In case an object contained a circular reference `Object.keys` was
called even though it was not necessary at all. This caused a
significant overhead for objects that contained a lot of such entries.
PR-URL: https://github.com/nodejs/node/pull/20007
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
2018-04-16 17:09:58 +02:00
davidmarkclements
5c425788f1
errors: alter ERR_INVALID_PROTOCOL
...
Changes the base instance for ERR_INVALID_PROTOCOL from Error to
TypeError as a more accurate representation of the error.
PR-URL: https://github.com/nodejs/node/pull/19983
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com >
2018-04-16 16:24:33 +02:00
Mathias Buus
f64bebf205
stream: add pipeline and finished
...
PR-URL: https://github.com/nodejs/node/pull/19828
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-04-16 16:02:12 +02:00
Alec Larson
5cc948b77a
fs: add 'close' event to FSWatcher
...
PR-URL: https://github.com/nodejs/node/pull/19900
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2018-04-16 14:23:11 +02:00
Vse Mozhet Byt
809eb27bda
doc: unify and compact some fragments in fs.md
...
PR-URL: https://github.com/nodejs/node/pull/20050
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
2018-04-16 14:13:27 +03:00
Vse Mozhet Byt
9f6742daa0
doc: update tools/doc/README.md
...
PR-URL: https://github.com/nodejs/node/pull/20047
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com >
2018-04-16 14:07:40 +03:00
Vse Mozhet Byt
6e869be104
doc: unify more headings
...
PR-URL: https://github.com/nodejs/node/pull/20046
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
2018-04-16 14:04:02 +03:00
Anatoli Papirovski
f7fbbeedc6
http: relax requirements on upgrade listener
...
The http spec does not say anything about Upgrade headers making
protocol switch mandatory but Node.js implements them as if they
are. Relax the requirements to only destroy the socket if no
upgrade listener exists on the client when status code is 101.
PR-URL: https://github.com/nodejs/node/pull/19981
Fixes: https://github.com/nodejs/node/issues/11552
Refs: https://tools.ietf.org/html/rfc7230#section-6.7
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
2018-04-16 11:02:23 +02:00
James M Snell
cf48d1db66
doc: clarify url doc
...
Indicate that `base` is ignored if `input` is absolute.
PR-URL: https://github.com/nodejs/node/pull/19899
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
2018-04-16 10:26:17 +02:00
davidmarkclements
345e3b28c6
errors: alter ERR_INVALID_DOMAIN_NAME
...
Changes the base instance for ERR_INVALID_DOMAIN_NAME from Error to
TypeError as a more accurate representation of the error.
PR-URL: https://github.com/nodejs/node/pull/19961
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
2018-04-16 10:14:39 +02:00
Rémi Berson
978e1524bb
timers: fix clearInterval to work with timers from setTimeout
...
According to HTML Living Standard, "either method [clearInterval or
clearTimeout] can be used to clear timers created by setTimeout() or
setInterval().".
The current implementation of clearTimeout is already able to destroy a
timer created by setInterval, but not the other way around.
PR-URL: https://github.com/nodejs/node/pull/19952
Refs: https://html.spec.whatwg.org/multipage/timers-and-user-prompts.html#dom-setinterval
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com >
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com >
2018-04-16 04:42:30 +02:00
Rod Vagg
2b6bb9f588
deps: c-ares float, win ipv6 bad fec0 prefix
...
Was 72c5458aee :
PR-URL: https://github.com/nodejs/node/pull/5090
Reviewed-By: Fedor Indutny <fedor@indutny.com >
Reimplemented for c-ares 1.13.0
PR-URL: https://github.com/nodejs/node/pull/15378
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
PR-URL: https://github.com/nodejs/node/pull/19939
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
2018-04-16 04:39:43 +02:00
Rod Vagg
de66bd34b9
deps: c-ares float, manual ares_ssize_t definition
...
c-ares switched to using ares_ssize_t for platform-independent ssize_t,
our GYP usage to include config/<platform>/ares_config.h causes problems
when including gyp as a library in core, i.e. in env.h and cares_wrap.h,
where the defines don't get pulled in properly. This, so far, is the
easiest approach to just making it work nicely--explicitly defining
ares_ssize_t for the different Windows variants and ssize_t for
non-Windows where we don't have a configured type from an ares_config.h.
In all of our non-Windows platforms it is ssize_t anyway so this is
safe.
PR-URL: https://github.com/nodejs/node/pull/15378
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
PR-URL: https://github.com/nodejs/node/pull/19939
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
2018-04-16 04:39:43 +02:00
Rod Vagg
b0b7afcfbe
deps: upgrade to c-ares v1.14.0
...
* Fix patch for CVE-2017-1000381 to not be overly aggressive.
* win32: Preserve DNS server order returned by Windows when sorting and
exclude DNS servers in legacy subnets.
* win32: Support most recent Visual Studio 2017.
* gethostbyaddr should fail with ECANCELLED not ENOTFOUND when
ares_cancel is called.
* win32: Exclude legacy ipv6 subnets.
* android: Applications compiled for Oreo can no longer use
__system_property_get and must use Java calls to retrieve DNS
servers.
* win32: Force use of ANSI functions.
* CMake minimum version is now 3.1.
* ares_gethostbyname.3: fix callback status values.
* docs: Document WSAStartup requirement.
* Fix a typo in init_by_resolv_conf.
* Android JNI code leaks local references in some cases.
* Force using the ANSI versions of WinAPI functions.
The most important changes have already been included via
* 50e580df21 deps: cherry-pick 0ef4a0c64b6 from c-ares upstream
* 9a0631dffe deps: cherry-pick 18ea996 from c-ares upstream
PR-URL: https://github.com/nodejs/node/pull/19939
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
2018-04-16 04:36:40 +02:00
Beth Griggs
4a0dff785e
build: remove implied support for win 2012 not R2
...
PR-URL: https://github.com/nodejs/node/pull/19378
Reviewed-By: Franziska Hinkelmann <franziska.hinkelmann@gmail.com >
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com >
Reviewed-By: Nikolai Vavilov <vvnicholas@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
2018-04-16 03:23:03 +02:00
Ruben Bridgewater
1d6cdfce80
doc: improve assert documentation
...
This adds a example to `assert.throws` to document checking against
error instances. It also makes it clearer what some arguments can
receive as input.
PR-URL: https://github.com/nodejs/node/pull/19885
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
2018-04-16 03:21:45 +02:00
Ruben Bridgewater
f7496896c4
tools: add eslintrc rule for assert.rejects
...
This makes sure `assert.rejects` is always called with a second
argument. Besides that it is also changes a eslint error message
to suggest objects instead of a regular expression.
PR-URL: https://github.com/nodejs/node/pull/19885
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
2018-04-16 03:21:45 +02:00
Ruben Bridgewater
2c3146d06d
assert: add direct promises support in rejects
...
This adds direct promise support to `assert.rejects` and
`assert.doesNotReject`. It will now accept both, functions and ES2015
promises as input.
Besides this the documentation was updated to reflect the latest
changes.
It also refactors the tests to a non blocking way to improve the
execution performance and improves the coverage.
PR-URL: https://github.com/nodejs/node/pull/19885
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
2018-04-16 03:21:45 +02:00
Antoine du HAMEL
11819c7773
fs: handle long files reading in fs.promises
...
PR-URL: https://github.com/nodejs/node/pull/19643
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
2018-04-15 18:10:49 -07:00
Anna Henningsen
85e1819d8b
lib: fix coverage reporting
...
Taking the source code of a function and running it in another
context does not play well with coverage instrumentation.
For now, do the simple thing and just write the source code as
a string literal.
Fixes: https://github.com/nodejs/node/issues/19912
Refs: https://github.com/nodejs/node/pull/19524
PR-URL: https://github.com/nodejs/node/pull/20035
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
2018-04-15 22:39:53 +02:00
Gus Caplan
c974f1bbe8
util: introduce types.isModuleNamespaceObject
...
PR-URL: https://github.com/nodejs/node/pull/20016
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Guy Bedford <guybedford@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2018-04-15 12:46:27 -07:00
Gus Caplan
ebe499f0c7
deps: cherry-pick 39d546a from upstream V8
...
Original commit message:
[api] introduce v8::Value::IsModuleNamespaceObject
This allows an embedder to check if a Value is a module namespace object.
Cq-Include-Trybots: luci.chromium.try:linux_chromium_rel_ng
Change-Id: Idffceff451dd5f5c6a53d4cb3ce02c1c2c5b653c
Reviewed-on: https://chromium-review.googlesource.com/1011762
Reviewed-by: Georg Neis <neis@chromium.org >
Commit-Queue: Georg Neis <neis@chromium.org >
Cr-Commit-Position: refs/heads/master@{#52597}
Refs: 39d546a240
PR-URL: https://github.com/nodejs/node/pull/20016
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Guy Bedford <guybedford@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2018-04-15 12:46:19 -07:00
Gus Caplan
73f13ba2fc
test: remove expectations based on v8 headers from types test
...
PR-URL: https://github.com/nodejs/node/pull/20003
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
2018-04-15 07:38:21 -07:00
Vse Mozhet Byt
ff4ca647d4
doc: unify format of iterables
...
Also, make signatures easier for copy-paste testing.
PR-URL: https://github.com/nodejs/node/pull/20036
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2018-04-15 11:36:07 +03:00
Joseph Gordon
b003c86bf4
doc: improved flow for macOS firewall script
...
PR-URL: https://github.com/nodejs/node/pull/18689
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
2018-04-14 20:18:03 -07:00
Vse Mozhet Byt
715d7f31b3
doc: unify section structures
...
PR-URL: https://github.com/nodejs/node/pull/20028
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
2018-04-15 02:37:50 +03:00
Bartosz Sosnowski
887f4c54ce
win, tools: add nasm to boxstarter script
...
Adds NASM installation to the Boxstarter script.
Refs: https://github.com/nodejs/node/issues/19918
PR-URL: https://github.com/nodejs/node/pull/19950
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-04-14 13:34:43 -07:00
davidmarkclements
cc7bef9eed
errors: alter ERR_HTTP2_PSEUDOHEADER_NOT_ALLOWED
...
changes the base instance for ERR_HTTP2_PSEUDOHEADER_NOT_ALLOWED
from Error to TypeError as a more accurate representation
of the error..
PR-URL: https://github.com/nodejs/node/pull/19958
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Yuta Hiroto <hello@hiroppy.me >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
2018-04-14 13:18:21 -07:00
Snehil Verma
e76831be0c
stream: fix incorrect comment in _stream_readable.js
...
PR-URL: https://github.com/nodejs/node/pull/19882
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-04-14 13:15:02 -07:00
Ben Noordhuis
45f6dccae1
deps: cherry-pick b767cde1e7 from upstream V8
...
Original commit message:
[intl] unbreak build with ICU 57
Remove a call to `icu::toUCharPtr()` that wasn't present in other
similar looking call sites either, just reinterpret_cast directly.
Fixes https://github.com/nodejs/node/issues/19656 .
Cq-Include-Trybots: luci.v8.try:v8_linux_noi18n_rel_ng
Change-Id: If281ce0a39356aa8bd20efb24c3e4b52b06841a3
Reviewed-on: https://chromium-review.googlesource.com/987953
Reviewed-by: Daniel Ehrenberg <littledan@chromium.org >
Commit-Queue: Ben Noordhuis <info@bnoordhuis.nl >
Cr-Commit-Position: refs/heads/master@{#52311}
PR-URL: https://github.com/nodejs/node/pull/19710
Fixes: https://github.com/nodejs/node/issues/19656
Refs: b767cde1e7
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Steven R Loomis <srloomis@us.ibm.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
PR-URL: https://github.com/nodejs/node/pull/19980
Reviewed-By: Ali Ijaz Sheikh <ofrobots@google.com >
Reviewed-By: Yang Guo <yangguo@chromium.org >
2018-04-14 12:59:26 -07:00
Chin Huang
09c63460eb
src: add sync trace to fs
...
Add sync trace to fs operations which
is enabled by the node.fs.sync trace event
category. Also add a general test js file
to verify all operations.
PR-URL: https://github.com/nodejs/node/pull/19649
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com >
2018-04-14 12:45:25 -07:00
Harry Sarson
c1a05e5c26
tools: fix broken link in icu notes
...
Link text and url were swapped around, this pr puts
the link text inside [] and the url inside ().
PR-URL: https://github.com/nodejs/node/pull/20030
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
2018-04-14 12:25:59 -07:00
Ujjwal Sharma
6eaeabcbec
src: add HandleScope to fix error
...
Add `HandleError`s to the AsyncScope constructor and destructor in
async_wrap-inl.h to fix "FATAL ERROR" incurring observed while running
test-http2-respond-with-file using the --trace-events-enabled flag.
Fixes: https://github.com/nodejs/node/issues/19921
PR-URL: https://github.com/nodejs/node/pull/19972
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-04-14 12:10:32 -07:00
Indranil Dasgupta
594e59d18d
doc: close event does not take arguments
...
Explicitly added in the docs that the close event does not expect
any arguments when invoked.
Fixes: https://github.com/nodejs/node/issues/20018
PR-URL: https://github.com/nodejs/node/pull/20031
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-04-14 12:08:39 -07:00
Daniel Bevenius
1d72434c8b
test: remove test case 0 from tls-cnnic-whitelist
...
I looks like this test has not worked as expected since commit
2bc7841d0f ("test: use random ports
where possible"). The test in that commit checked for `CERT_REVOKED`
which was returned by CheckWhitelistedServerCert.
CheckWhitelistedServerCert was later removed in commit
dc875438a3 ("src: drop CNNIC+StartCom
certificate whitelisting").
I'm suggesting that this test case be removed as I don't think it is
valid anymore.
PR-URL: https://github.com/nodejs/node/pull/19767
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2018-04-14 11:45:59 -07:00
Daniel Bevenius
7a33c2cc7c
test: set clientOpts.port property
...
Currently this test will overwrite the clientOpts object with the port,
instead of setting the port property on the clientOpts object which
looks like the original intent.
Doing this the test fails reporting that the fake-cnnic-root-cert has
expired. This is indeed true:
$ openssl x509 -in test/fixtures/keys/fake-cnnic-root-cert.pem \
-text -noout
Certificate:
...
Validity
Not Before: Jun 9 17:15:16 2015 GMT
Not After : Mar 29 17:15:16 2018 GMT
This commit sets the errorCode to CERT_HAS_EXPIRED. I tried updating the
certificate using test/fixtures/keys/Makefile but then no error is
thrown and I'm currently looking into this.
PR-URL: https://github.com/nodejs/node/pull/19767
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2018-04-14 11:45:47 -07:00
Daniel Bevenius
5879f480b1
test: update keys/Makefile to clean and build all
...
Currently when running make clean, followed by make not all certificates
get genenerated. In addition there are also the following error messages
related to the startdate in agent8-cert.pem, and agent9-cert.pem:
start date is invalid, it should be YYMMDDHHMMSSZ
After this commit it is possible to perform the following commands:
$ make clean
$ make
$ make test
PR-URL: https://github.com/nodejs/node/pull/19975
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-04-14 11:38:41 -07:00
davidmarkclements
8826cc985a
errors: alter and test ERR_INVALID_REPL_EVAL_CONFIG
...
changes the base instance for ERR_INVALID_REPL_EVAL_CONFIG
from Error to TypeError as a more accurate representation
of the error and adds a unit test for the repl options that
trigger this error.
PR-URL: https://github.com/nodejs/node/pull/19984
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
2018-04-14 11:33:43 -07:00
Rich Trott
6dca62b28d
doc: include error code in buffer documentation
...
Replace mentions of `RangeError` with the specific error code (e.g.,
`ERR_INVALID_OPT_VALUE`). Minor improvements to nearby text (wrap at 80
chars, serial comma, remove unnecessary articles, use present tense
consistently).
PR-URL: https://github.com/nodejs/node/pull/19982
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Beth Griggs <Bethany.Griggs@uk.ibm.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
2018-04-14 11:32:09 -07:00