0
0
mirror of https://github.com/nodejs/node.git synced 2024-12-01 16:10:02 +01:00
Commit Graph

16213 Commits

Author SHA1 Message Date
Timothy Gu
06ecf4dec7 url: define @@toStringTag as a data property
Even though this is not fully Web IDL spec-compliant, it is arguably the
best we can do. Following the spec would mean non-trivial performance
deterioration (10% when parsing a medium-length URL), while the current
getter behavior is not adopted by any implementer, and it causes some
spec ambiguity when the getter is called with !(this instanceof URL).

This commit adopts Chrome's behavior, and is consistent with
ECMAScript-defined classes while providing reasonable behaviors for
corner cases as well. Until the Web IDL spec is changed one way or
another, this is the way to go.

PR-URL: https://github.com/nodejs/node/pull/10906
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
2017-01-28 08:27:15 -08:00
Timothy Gu
d65904bc6a url: do not public expose inspect methods on URL
PR-URL: https://github.com/nodejs/node/pull/10906
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
2017-01-28 08:27:09 -08:00
Joyee Cheung
f3dc6a37f0 buffer, test: add tests for buffer.toJSON
* Pull out the tests for buffer.toJSON from test-buffer-alloc
* Add tests for serializing a 0-length buffer

PR-URL: https://github.com/nodejs/node/pull/10979
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2017-01-28 23:58:33 +08:00
Ben Noordhuis
56f4f09aa8 doc: remove Chris Dickinson from active releasers
The last release Chris did was v1.8.1 from April 2015.

PR-URL: https://github.com/nodejs/node/pull/11011
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Evan Lucas <evanlucas@me.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
Reviewed-By: Сковорода Никита Андреевич <chalkerx@gmail.com>
2017-01-28 12:29:28 +01:00
Aashil Patel
5d27cc1d0d src: fix the misalinged text on "node --help"
The alignment of the argument descriptions in the "node --help"
text is off. This commit fixes the issue by adding two spaces
before each of the argument description.

PR-URL: https://github.com/nodejs/node/pull/10948
Fixes: https://github.com/nodejs/node/issues/10935
Reviewed-By: Evan Lucas <evanlucas@me.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Josh Gavant <josh.gavant@outlook.com>
2017-01-27 16:31:55 -08:00
Sam Roberts
38161f0a95 doc: for style, remove "isn't" contraction
PR-URL: https://github.com/nodejs/node/pull/10981
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
2017-01-27 14:23:33 -08:00
Evan Lucas
4f1e235f2a doc: make os api doc more consistent
This adds a missing Returns to os.arch() as well as a missing added in
version to os.constants.

PR-URL: https://github.com/nodejs/node/pull/10994
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2017-01-27 13:55:07 -08:00
abouthiroppy
7ad012dbb1 test: increase coverage for stream's duplex
Make use of Arrow function.
Add a small test and this file's coverage is 100%.
a647d82f83/lib/_stream_duplex.js (L25)
Coverage: https://coverage.nodejs.org/coverage-067be658f966dafe/root/_stream_duplex.js.html

PR-URL: https://github.com/nodejs/node/pull/10963
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Italo A. Casas <me@italoacasas.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
2017-01-27 13:50:20 -08:00
Javis Sullivan
3268863ebc child_process: add string shortcut for fork stdio
Add string shortcut option for stdio parameter.

Fixes: https://github.com/nodejs/node/issues/10793
PR-URL: https://github.com/nodejs/node/pull/10866
Reviewed-By: Sam Roberts <vieuxtech@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Brian White <mscdex@mscdex.net>
2017-01-27 12:06:48 -08:00
Rich Trott
b6d2fc9b0f test: allow for slow hosts in spawnSync() test
test-child-process-spawnsync-timeout failed from time to time on
Raspberry Pi devices. Use common.platformTimeout() to allow a little
more time to run on resource-constrained hosts.

PR-URL: https://github.com/nodejs/node/pull/10998
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2017-01-27 12:03:06 -08:00
Jeremiah Senkpiel
c74e6fe651 benchmark: add more thorough timers benchmarks
Refs: https://github.com/nodejs/node/issues/9493
PR-URL: https://github.com/nodejs/node/pull/10925
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Trevor Norris <trev.norris@gmail.com>
2017-01-27 14:26:24 -05:00
Vinícius do Carmo
b19334e566 test: expand test coverage of fs.js
* test reading a file passing a not valid enconding

Refs: https://coverage.nodejs.org/coverage-067be658f966dafe/root/internal/fs.js.html
PR-URL: https://github.com/nodejs/node/pull/10947
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
2017-01-27 16:21:59 +00:00
Vinícius do Carmo
bee83e0bbc test: expand test coverage of events.js
* test else path in emitMany function
* test calling removeAllListeners() in a event emitter instance
  with no events at all
* test calling removeListener() passing a event type that does
  not exist
* test calling eventNames() in a event emitter instance
  with no events at all

Refs: https://coverage.nodejs.org/coverage-ba776b3a56642d4c/root/events.js.html
PR-URL: https://github.com/nodejs/node/pull/10947
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
2017-01-27 16:20:50 +00:00
Timothy Gu
e71c278288 url: stop exporting originFor()
PR-URL: https://github.com/nodejs/node/pull/10955
Fixes: https://github.com/nodejs/node/issues/10800
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
2017-01-27 07:35:36 -08:00
Michaël Zasso
ad6e778c4a benchmark: add benchmark for object properties
Adds a benchmark to compare the speed of property setting/getting in
four cases:
- Dot notation: `obj.prop = value`
- Bracket notation with string: `obj['prop'] = value`
- Bracket notation with string variable: `obj[prop] = value`
- Bracket notation with Symbol variable: `obj[sym] = value`

PR-URL: https://github.com/nodejs/node/pull/10949
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
2017-01-27 13:00:42 +01:00
larissayvette
084acc819d test: check noAssert option in buf.write*()
Add test to cover previously untested `noAssert` functionality in
buf.write*() functions.

PR-URL: https://github.com/nodejs/node/pull/10790
Reviewed-By: Rich Trott <rtrott@gmail.com>
2017-01-26 14:11:44 -08:00
Brian White
24ef1e6775 string_decoder: align UTF-8 handling with V8
V8 5.5 changed how invalid characters are handled and it now appears
to follow the WHATWG Encoding standard, where all of an invalid
character's bytes are replaced by a single replacement character
(\ufffd) instead of replacing each invalid byte with separate
replacement characters.

Example: the byte sequence 0xF0,0xB8,0x41 is decoded as '\ufffdA' in
V8 5.5, but is decoded as '\ufffd\ufffdA' in previous versions of V8.

PR-URL: https://github.com/nodejs/node/pull/9618
Reviewed-By: Ali Ijaz Sheikh <ofrobots@google.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2017-01-26 22:46:18 +01:00
Michaël Zasso
007386ee81 repl: remove workaround for function redefinition
The issue is fixed upstream in V8. Thus we do not need this workaround
in REPL.

Fixes: https://github.com/nodejs/node/issues/548
PR-URL: https://github.com/nodejs/node/pull/9618
Reviewed-By: Ali Ijaz Sheikh <ofrobots@google.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2017-01-26 22:46:18 +01:00
Franziska Hinkelmann
c2c6ae52ea test: move test-vm-function-redefinition to parallel
With the upstream fix in V8, function declarations now
work fine in the vm module and the test is no longer failing.

Refs: https://codereview.chromium.org/2334733002
Fixes: https://github.com/nodejs/node/issues/548
PR-URL: https://github.com/nodejs/node/pull/9618
Reviewed-By: Ali Ijaz Sheikh <ofrobots@google.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2017-01-26 22:46:18 +01:00
Michael Dawson
b37f55a1ba deps: limit regress/regress-crbug-514081 v8 test
regress/regress-crbug-514081 allocates a 2G block of memory
and if there  are multiple variants running at the
same time this can lead to crashes, OOM kills or
the OS failing to allocate memory.  This patch
limits us to running a single variant of the test

Fixes: https://github.com/nodejs/node/issues/6340
PR-URL: https://github.com/nodejs/node/pull/6678
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Fedor Indutny <fedor@indutny.com>
2017-01-26 22:46:18 +01:00
Michaël Zasso
91ab09fe2a src: update NODE_MODULE_VERSION to 52
V8 5.5 is not API/ABI compatible with 5.4.
This commit increments NODE_MODULE_VERSION by one.

Refs: https://github.com/nodejs/CTC/blob/master/meetings/2016-09-28.md
PR-URL: https://github.com/nodejs/node/pull/9618
Reviewed-By: Ali Ijaz Sheikh <ofrobots@google.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2017-01-26 22:46:18 +01:00
Michaël Zasso
2739185b79 deps: update V8 to 5.5.372.40
PR-URL: https://github.com/nodejs/node/pull/9618
Reviewed-By: Ali Ijaz Sheikh <ofrobots@google.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2017-01-26 22:46:17 +01:00
Shigeki Ohtsu
a67a04d765 deps: update openssl asm and asm_obsolete files
Regenerate asm files with Makefile and CC=gcc and ASM=gcc where
gcc-5.4.0. Also asm files in asm_obsolete dir to support old compiler
and assembler are regenerated without CC and ASM envs

PR-URL: https://github.com/nodejs/node/pull/11021
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2017-01-27 01:59:46 +09:00
Shigeki Ohtsu
2a74481f20 deps: add -no_rand_screen to openssl s_client
In openssl s_client on Windows, RAND_screen() is invoked to initialize
random state but it takes several seconds in each connection.
This added -no_rand_screen to openssl s_client on Windows to skip
RAND_screen() and gets a better performance in the unit test of
test-tls-server-verify.
Do not enable this except to use in the unit test.

Fixes: https://github.com/nodejs/io.js/issues/1461
PR-URL: https://github.com/nodejs/io.js/pull/1836
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2017-01-27 01:59:46 +09:00
Shigeki Ohtsu
0ea271107e openssl: fix keypress requirement in apps on win32
Reapply b910613792 .

Fixes: https://github.com/iojs/io.js/issues/589
PR-URL: https://github.com/iojs/io.js/pull/1389
Reviewed-By: Fedor Indutny <fedor@indutny.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2017-01-27 01:59:46 +09:00
Shigeki Ohtsu
809fa3bf86 deps: fix asm build error of openssl in x86_win32
See
https://mta.openssl.org/pipermail/openssl-dev/2015-February/000651.html

iojs needs to stop using masm and move to nasm or yasm on Win32.

Fixes: https://github.com/iojs/io.js/issues/589
PR-URL: https://github.com/iojs/io.js/pull/1389
Reviewed-By: Fedor Indutny <fedor@indutny.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2017-01-27 01:59:46 +09:00
Fedor Indutny
0af423cb04 deps: fix openssl assembly error on ia32 win32
`x86masm.pl` was mistakenly using .486 instruction set, why `cpuid` (and
perhaps others) are requiring .686 .

Fixes: https://github.com/iojs/io.js/issues/589
PR-URL: https://github.com/iojs/io.js/pull/1389
Reviewed-By: Fedor Indutny <fedor@indutny.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Shigeki Ohtsu <ohtsu@iij.ad.jp>
2017-01-27 01:59:46 +09:00
Shigeki Ohtsu
c0eefcb461 deps: copy all openssl header files to include dir
All symlink files in `deps/openssl/openssl/include/openssl/`
are removed and replaced with real header files to avoid
issues on Windows. Two files of opensslconf.h in crypto and
include dir are replaced to refer config/opensslconf.h.

PR-URL: https://github.com/nodejs/node/pull/11021
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2017-01-27 01:59:00 +09:00
Shigeki Ohtsu
31e3b81290 deps: upgrade openssl sources to 1.0.2k
This replaces all sources of openssl-1.0.2k.tar.gz into
deps/openssl/openssl

PR-URL: https://github.com/nodejs/node/pull/11021
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2017-01-27 01:57:46 +09:00
Vinícius do Carmo
efbda74686 test: expand test coverage of fs.js
* test calling truncateSync() passing a file descriptor
* test calling truncate() passing undefined as the 2nd argument

Refs: https://coverage.nodejs.org/coverage-8ab561b2432bdae3/root/fs.js.html
      (line 673 and 692)

PR-URL: https://github.com/nodejs/node/pull/10972
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
2017-01-26 11:36:08 -05:00
Rebecca Turner
f73bc91756 deps: upgrade npm to 4.1.1
PR-URL: https://github.com/nodejs/node/pull/10781
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
2017-01-26 10:56:33 -05:00
Ben Noordhuis
bfd3c7e626 src: move trace_event.h include to internal header
Move the include from src/node.h to src/node_internals.h.

trace_event.h is not shipped in binary-only and headers-only tarballs,
making it currently impossible to build add-ons against them.

PR-URL: https://github.com/nodejs/node/pull/10959
Refs: https://github.com/nodejs/citgm/pull/226#issuecomment-274066280
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Matthew Loring <mattloring@google.com>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Stephen Belanger <admin@stephenbelanger.com>
2017-01-26 01:48:25 +01:00
Rich Trott
997af07249 test: enhance test-timers
In test-timers, confirm that all input values that should be coerced to
1 ms are not being coerced to a significantly larger value.

This eliminates the need for the separate test-regress-GH-897.

PR-URL: https://github.com/nodejs/node/pull/10960
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2017-01-25 15:55:01 -08:00
Anna Henningsen
1ef38e9fed
test: add regression tests for vm bugs
Add the regression test script presented in
https://github.com/nodejs/node/issues/10806 to `test/parallel` and
re-add the original regression test for
https://github.com/nodejs/node/issues/10223 in `test/known_issues`.

PR-URL: https://github.com/nodejs/node/pull/10920
Reviewed-By: Franziska Hinkelmann <franziska.hinkelmann@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2017-01-25 15:44:29 -08:00
Anna Henningsen
3e851cf18b
Revert "src: don't overwrite non-writable vm globals"
This reverts commit 524f693872.

Fixes: https://github.com/nodejs/node/issues/10806
Fixes: https://github.com/nodejs/node/issues/10492
Ref: https://github.com/nodejs/node/pull/10227
PR-URL: https://github.com/nodejs/node/pull/10920
Reviewed-By: Franziska Hinkelmann <franziska.hinkelmann@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2017-01-25 15:43:51 -08:00
Rich Trott
dd928b04fc zlib: be strict about what strategies are accepted
Currently, strategy constants are integers but Node.js will accept
string versions of those integers. Users should be using the provided
zlib constants and not hardcoding numbers, strings, or anything else. As
such, Node.js should be strict about accepting only exactly those values
that are in the provided zlib constants.

PR-URL: https://github.com/nodejs/node/pull/10934
Fixes: https://github.com/nodejs/node/issues/10932
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2017-01-25 14:07:43 -08:00
Phillip Johnsen
01b90ee1db tools,doc: add Google Analytics tracking.
Adds Google Analytics tracking script to all doc pages when
`DOCS_ANALYTICS` is set when running `make`:

```bash
$ DOCS_ANALYTICS=<GOOGLE ANALYTICS ID> make
```

By default (when `DOCS_ANALYTICS` is not set), no tracking scripts are
included.

It respects "Do Not Track" settings end users might have in their
browser.

Also changes make target `doc-upload` from depending on the
`$(TARBALL)` target, to only depend on `doc` directly.

PR-URL: https://github.com/nodejs/node/pull/6601
Reviewed-By: Johan Bergström <bugs@bergstroem.nu>
Reviewed-By: Rod Vagg <rod@vagg.org>
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
2017-01-25 21:54:34 +01:00
Sam Roberts
124d155f5e doc: DEFAULT_ECDH_CURVE was added in 0.11.13
Document this with the YAML meta-data.

PR-URL: https://github.com/nodejs/node/pull/10983
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2017-01-25 09:32:13 -08:00
Lance Ball
3b9e8adad4
doc: update http.md for consistency and clarity
The HTTP Keep-Alive text was inconsistent. These changes follow the
following rules

* When referring to flag used in code, it should always be written using
  backticks and in camel case. E.g. `keepAlive`.
* When referring to the mechanism Keep-Alive functionality as described
  in the HTTP 1.1 RFC, it is written as 'HTTP Keep-Alive', without the
  use of backticks.
* When referring to the request header, it should always use backticks
  and be written as `Connection: keep-alive`.

This commit also includes some changes to how `http.Agent` is
referenced. When `Agent` is used as a reference to an object or
instance, backticks should always be used.

And lastly, the documentation about `Agent` behavior around HTTP
Keep-Alive has been clarified and improved.

Fixes: https://github.com/nodejs/node/issues/10567
PR-URL: https://github.com/nodejs/node/pull/10715

Reviewed-By: Sam Roberts <vieuxtech@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2017-01-25 10:31:59 -05:00
cjihrig
58cb9cde91 test: increase coverage for exec() functions
This commit increases code coverage related to the stdout
and stderr outputs of the child_process exec() functions.
Previously, stdout was completely covered, but stderr was
not.

PR-URL: https://github.com/nodejs/node/pull/10919
Reviewed-By: Sam Roberts <vieuxtech@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
2017-01-25 09:33:56 -05:00
abouthiroppy
aa4fe92392 test: add process.assert's test
PR-URL: https://github.com/nodejs/node/pull/10911
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Italo A. Casas <me@italoacasas.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2017-01-25 12:51:15 +01:00
Brian White
3bdcbdb1a0
querystring: improve unescapeBuffer performance
PR-URL: https://github.com/nodejs/node/pull/10837
Reviewed-By: James M Snell <jasnell@gmail.com>
2017-01-25 02:22:26 -05:00
Brian White
05f38be556
querystring: improve stringify() performance
PR-URL: https://github.com/nodejs/node/pull/10852
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Claudio Rodriguez <cjrodr@yahoo.com>
2017-01-25 02:15:03 -05:00
Brian White
2298bc4b1f
querystring: improve parse() performance
PR-URL: https://github.com/nodejs/node/pull/10874
Reviewed-By: James M Snell <jasnell@gmail.com>
2017-01-25 02:05:26 -05:00
Brian White
9e0f6a5eb4
buffer: improve compare() performance
PR-URL: https://github.com/nodejs/node/pull/10927
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
2017-01-25 01:42:42 -05:00
dcposch@dcpos.ch
39f65e6656
buffer: fix comments in bidirectionalIndexOf
PR-URL: https://github.com/nodejs/node/pull/10162
Fixes: https://github.com/nodejs/node/issues/9801
Reviewed-By: Roman Reiss <me@silverwind.io>
Reviewed-By: Stephen Belanger <admin@stephenbelanger.com>
Reviewed-By: Trevor Norris <trev.norris@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
2017-01-25 00:37:50 +01:00
dcposch@dcpos.ch
d0112fc716
doc: clarify Buffer.indexOf/lastIndexOf edge cases
PR-URL: https://github.com/nodejs/node/pull/10162
Fixes: https://github.com/nodejs/node/issues/9801
Reviewed-By: Roman Reiss <me@silverwind.io>
Reviewed-By: Stephen Belanger <admin@stephenbelanger.com>
Reviewed-By: Trevor Norris <trev.norris@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
2017-01-25 00:37:38 +01:00
dcposch@dcpos.ch
dd50cd9e4f
test: update Buffer.lastIndexOf
Test type coercion for non-number offset arguments. Verify that Buffer
and String behave the same way.

PR-URL: https://github.com/nodejs/node/pull/10162
Fixes: https://github.com/nodejs/node/issues/9801
Reviewed-By: Roman Reiss <me@silverwind.io>
Reviewed-By: Stephen Belanger <admin@stephenbelanger.com>
Reviewed-By: Trevor Norris <trev.norris@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
2017-01-25 00:37:37 +01:00
John Barboza
0a9f360c98
src: support "--" after "-e" as end-of-options
When the double dash "--" appears after "-e <script>" on the
command line, it indicates the end of options and the beginning
of positional parameters for the script.

PR-URL: https://github.com/nodejs/node/pull/10651
Reviewed-By: Sam Roberts <vieuxtech@gmail.com>
Reviewed-By: Roman Reiss <me@silverwind.io>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
2017-01-25 00:24:40 +01:00
Travis Meisenheimer
5ea98fb17d crypto: return the retval of HMAC_Update
Fixes coverity scan issue 55489.

PR-URL: https://github.com/nodejs/node/pull/10891
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Sam Roberts <vieuxtech@gmail.com>
Reviewed-By: Brian White <mscdex@mscdex.net>
2017-01-24 14:26:22 -08:00