platform/upstream/nodejs.git
8 years agotest: add tests for persistent repl history
Jeremiah Senkpiel [Sun, 2 Aug 2015 05:38:28 +0000 (22:38 -0700)]
test: add tests for persistent repl history

PR-URL: https://github.com/nodejs/io.js/pull/2224
Reviewed-By: Michaël Zasso <mic.besace@gmail.com>
Reviewed-By: Chris Dickinson <christopher.s.dickinson@gmail.com>
Reviewed-By: Roman Reiss <me@silverwind.io>
8 years agodoc: document repl persistent history changes
Jeremiah Senkpiel [Tue, 4 Aug 2015 06:33:48 +0000 (23:33 -0700)]
doc: document repl persistent history changes

PR-URL: https://github.com/nodejs/io.js/pull/2224
Reviewed-By: Michaël Zasso <mic.besace@gmail.com>
Reviewed-By: Chris Dickinson <christopher.s.dickinson@gmail.com>
Reviewed-By: Roman Reiss <me@silverwind.io>
8 years agosrc: disable vector ICs on arm
Michaël Zasso [Thu, 30 Jul 2015 10:05:20 +0000 (12:05 +0200)]
src: disable vector ICs on arm

A bug on ARMv6 makes the process crash when the V8 debugger is used.
Disabling vector ICs as a workaround.

V8-Bug: https://code.google.com/p/v8/issues/detail?id=4338
PR-URL: https://github.com/nodejs/io.js/pull/2220
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Ali Ijaz Sheikh <ofrobots@google.com>
Reviewed-By: Rod Vagg <rod@vagg.org>
8 years agodeps: update V8 to 4.4.63.26
Michaël Zasso [Mon, 27 Jul 2015 06:43:54 +0000 (08:43 +0200)]
deps: update V8 to 4.4.63.26

Includes cherry-picks for:
 * JitCodeEvent patch: https://crrev.com/f7969b1d5a55e66237221a463daf422ac7611788
 * argparse patch: https://crrev.com/44bc918458481d60b08d5566f0f31a79e39b85d7

PR-URL: https://github.com/nodejs/io.js/pull/2220
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Ali Ijaz Sheikh <ofrobots@google.com>
Reviewed-By: Rod Vagg <rod@vagg.org>
8 years agohttp: fix agent.getName() and add tests
Brendan Ashworth [Tue, 5 May 2015 02:24:59 +0000 (19:24 -0700)]
http: fix agent.getName() and add tests

This commit fixes agent.getName(), which returned an extra colon
according to the docs, and adds tests (it was previously not unit
tested).

PR-URL: https://github.com/nodejs/io.js/pull/1617
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
8 years agoreadline: allow tabs in input
Rich Trott [Thu, 21 May 2015 04:17:10 +0000 (21:17 -0700)]
readline: allow tabs in input

If tab completion is not being used, allow user to enter tab
characters.

PR-URL: https://github.com/nodejs/io.js/pull/1761
Reviewed-By: Brendan Ashworth <brendan.ashworth@me.com>
8 years agobuild: prepare Windows installer for i18n support
Frederic Hemberger [Sat, 25 Jul 2015 11:33:32 +0000 (13:33 +0200)]
build: prepare Windows installer for i18n support

PR-URL: https://github.com/nodejs/io.js/pull/2247
Reviewed-By: Rod Vagg <rod@vagg.org>
8 years agonode: remove redundant --use-old-buffer
Rod Vagg [Thu, 30 Jul 2015 12:12:01 +0000 (22:12 +1000)]
node: remove redundant --use-old-buffer

Accidentally left when upgrading to V8 4.4.63.9

PR-URL: https://github.com/nodejs/io.js/pull/2275
Reviewed-By: Michaël Zasso <mic.besace@gmail.com>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
8 years agobuffer: fix missing null/undefined check
Trevor Norris [Thu, 16 Jul 2015 21:19:01 +0000 (15:19 -0600)]
buffer: fix missing null/undefined check

The new implementation of Buffer missed the check for null/undefined as
the first argument to new Buffer(). Reintroduce the check and add test.

Fix: e8734c0 "buffer: implement Uint8Array backed Buffer"
Fix: https://github.com/nodejs/io.js/issues/2194
PR-URL: https://github.com/nodejs/io.js/pull/2195
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Rod Vagg <rod@vagg.org>
8 years agobuild: add 'x86' option back in to configure
Rod Vagg [Fri, 24 Jul 2015 02:39:06 +0000 (12:39 +1000)]
build: add 'x86' option back in to configure

Accidentally removed @ https://github.com/nodejs/io.js/pull/2124
when ppc support was added

PR-URL: https://github.com/nodejs/io.js/pull/2233
Reviewed-By: Johan Bergstrom <bugs@bergstroem.nu>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
8 years agobuild: first set of updates to enable PPC support
Michael Dawson [Tue, 7 Jul 2015 18:15:03 +0000 (14:15 -0400)]
build: first set of updates to enable PPC support

These are the core changes that allow pLinux BE/LE compile. They
don't include all of the changes needed for AIX which will follow
once we have pLinux up and running in the builds

PR-URL: https://github.com/nodejs/io.js/pull/2124
Reviewed-By: Ben Noordhuis <ben@strongloop.com>
Reviewed-By: Johan Bergstrom <bugs@bergstroem.nu>
8 years agobuffer: fix not return on error
Trevor Norris [Wed, 22 Jul 2015 19:06:54 +0000 (13:06 -0600)]
buffer: fix not return on error

Throwing a JS error from C++ does not mean the function will return
early. This must be done manually.

Also remove extraneous comment no longer relevant.

Fix: 2903030 "buffer: switch API to return MaybeLocal<T>"
PR-URL: https://github.com/nodejs/io.js/pull/2225
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
8 years agonode-gyp: detect RC build with x.y.z-rc.n format
Rod Vagg [Mon, 13 Jul 2015 03:35:02 +0000 (13:35 +1000)]
node-gyp: detect RC build with x.y.z-rc.n format

PR-URL: https://github.com/nodejs/io.js/pull/2171
Reviewed-By: Alexis Campailla <alexis@janeasystems.com>
Reviewed-By: Johan Bergström <bugs@bergstroem.nu>
8 years agosrc: introduce process.release object
Rod Vagg [Sun, 18 Jan 2015 06:41:37 +0000 (17:41 +1100)]
src: introduce process.release object

PR-URL: https://github.com/nodejs/io.js/pull/2154
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
8 years agohttp: use official IANA Status Codes
jomo [Sat, 11 Jul 2015 00:01:52 +0000 (02:01 +0200)]
http: use official IANA Status Codes

* adds missing HTTP status codes
* corrects those with a wrong description
* the falsely included codes have been kept

PR-URL: https://github.com/nodejs/io.js/pull/1470
Reviewed-By: Brendan Ashworth <brendan.ashworth@me.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Brian White <mscdex@mscdex.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
8 years agonode: do not override `message`/`stack` of error
Fedor Indutny [Sun, 5 Jul 2015 18:20:26 +0000 (11:20 -0700)]
node: do not override `message`/`stack` of error

Put the `...^` arrow string to the hidden property of the object, and
use it only when printing error to the stderr.

Fix: https://github.com/nodejs/io.js/issues/2104
PR-URL: https://github.com/nodejs/io.js/pull/2108
Reviewed-By: Trevor Norris <trev.norris@gmail.com>
8 years agosrc: increment NODE_MODULE_VERSION to 45
Rod Vagg [Thu, 2 Jul 2015 04:34:49 +0000 (14:34 +1000)]
src: increment NODE_MODULE_VERSION to 45

PR-URL: https://github.com/nodejs/io.js/pull/2096
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
8 years agodeps: upgrade v8 to 4.4.63.12
Ben Noordhuis [Wed, 1 Jul 2015 22:50:48 +0000 (00:50 +0200)]
deps: upgrade v8 to 4.4.63.12

PR-URL: https://github.com/nodejs/io.js/pull/2092
Reviewed-By: Trevor Norris <trev.norris@gmail.com>
8 years agoWorking on v3.0.0
Rod Vagg [Tue, 30 Jun 2015 07:43:29 +0000 (17:43 +1000)]
Working on v3.0.0

8 years agonode-gyp: download header tarball for compile
Rod Vagg [Fri, 26 Jun 2015 12:19:30 +0000 (22:19 +1000)]
node-gyp: download header tarball for compile

Temporary fix only, node-gyp needs to be aware of whether it can even
download this file for the current runtime so that information needs to
come from the process itself.

Floating patch on npm.

PR-URL: https://github.com/nodejs/io.js/pull/2066
Reviewed-By: Johan Bergström <bugs@bergstroem.nu>
Reviewed-By: Ryan Graham <ryan@strongloop.com>
8 years agonode-gyp: make aware of nightly, next-nightly & rc
Rod Vagg [Fri, 26 Jun 2015 12:17:02 +0000 (22:17 +1000)]
node-gyp: make aware of nightly, next-nightly & rc

A temporary fix only, node-gyp needs to be made more intelligent
upstream about figuring out where to find the download file by
inspecting the binary.

Floating patch on npm.

PR-URL: https://github.com/nodejs/io.js/pull/2066
Reviewed-By: Johan Bergström <bugs@bergstroem.nu>
Reviewed-By: Ryan Graham <r.m.graham@gmail.com>
8 years agobuffer: rename internal/buffer_new.js to buffer.js
Ben Noordhuis [Fri, 19 Jun 2015 19:00:19 +0000 (21:00 +0200)]
buffer: rename internal/buffer_new.js to buffer.js

The old smalloc-based implementation has been removed, the typed array
implementation is the only one that is left now.

PR-URL: https://github.com/nodejs/io.js/pull/2022
Reviewed-By: Rod Vagg <rod@vagg.org>
Reviewed-By: Trevor Norris <trev.norris@gmail.com>
8 years agotest: remove two obsolete pummel tests
Ben Noordhuis [Fri, 19 Jun 2015 18:54:24 +0000 (20:54 +0200)]
test: remove two obsolete pummel tests

Remove two tests that assume creating big buffers fails.  The size limit
is twice as big on 64 bits architectures now and is going to be removed
completely in the not too distant future.

PR-URL: https://github.com/nodejs/io.js/pull/2022
Reviewed-By: Rod Vagg <rod@vagg.org>
Reviewed-By: Trevor Norris <trev.norris@gmail.com>
8 years agotest: don't use arguments.callee
Ben Noordhuis [Fri, 19 Jun 2015 18:45:30 +0000 (20:45 +0200)]
test: don't use arguments.callee

Fix a strict mode violation that made the test fail to run.  It appears
to be a regression that was introduced in commit f29762f ("test: enable
linting for tests") which I was the sole reviewer of, so mea culpa.

PR-URL: https://github.com/nodejs/io.js/pull/2022
Reviewed-By: Rod Vagg <rod@vagg.org>
Reviewed-By: Trevor Norris <trev.norris@gmail.com>
8 years agodeps: update v8 to 4.4.63.9
Ben Noordhuis [Fri, 19 Jun 2015 11:23:56 +0000 (13:23 +0200)]
deps: update v8 to 4.4.63.9

Upgrade the bundled V8 and update code in src/ and lib/ to the new API.

Notable backwards incompatible changes are the removal of the smalloc
module and dropped support for CESU-8 decoding.  CESU-8 support can be
brought back if necessary by doing UTF-8 decoding ourselves.

This commit includes https://codereview.chromium.org/1192973004 to fix
a build error on python 2.6 systems.  The original commit log follows:

    Use optparse in js2c.py for python compatibility

    Without this change, V8 won't build on RHEL/CentOS 6 because the
    distro python is too old to know about the argparse module.

PR-URL: https://github.com/nodejs/io.js/pull/2022
Reviewed-By: Rod Vagg <rod@vagg.org>
Reviewed-By: Trevor Norris <trev.norris@gmail.com>
8 years agobuffer: allow ArrayBuffer as Buffer argument
Trevor Norris [Wed, 17 Jun 2015 16:43:13 +0000 (10:43 -0600)]
buffer: allow ArrayBuffer as Buffer argument

Buffer now uses the ArrayBuffer as the backing store if passed to the
constructor.

Fixes: https://github.com/nodejs/io.js/issues/106
PR-URL: https://github.com/nodejs/io.js/pull/2002
Reviewed-By: Domenic Denicola <d@domenic.me>
8 years agobuffer: minor cleanup from rebase
Trevor Norris [Wed, 17 Jun 2015 17:42:00 +0000 (11:42 -0600)]
buffer: minor cleanup from rebase

PR-URL: https://github.com/nodejs/io.js/pull/2003
Reviewed-By: Chris Dickinson <christopher.s.dickinson@gmail.com>
8 years agobuffer: fix usage of kMaxLength
Trevor Norris [Wed, 17 Jun 2015 17:34:12 +0000 (11:34 -0600)]
buffer: fix usage of kMaxLength

Starting in V8 v4.3 the maximum array index of a typed array is the same
as the largest Smi supported on a given architecture. To compensate for
these differences export kMaxLength from the buffer module with the
correct size for the given architecture.

PR-URL: https://github.com/nodejs/io.js/pull/2003
Reviewed-By: Chris Dickinson <christopher.s.dickinson@gmail.com>
8 years agocluster: do not unconditionally set --debug-port
cjihrig [Thu, 11 Jun 2015 15:47:52 +0000 (11:47 -0400)]
cluster: do not unconditionally set --debug-port

Currently, each cluster worker is assigned an ever increasing
--debug-port argument. A long running cluster application that
does not use the debugger can run into errors related to the
port range. This commit mitigates the problem by only setting
the debug port if the master is started with debug arguments, or
the user explicitly defines debug arguments for the worker. This
commit also adds a new debug port offset counter that is only
incremented when a worker is created that utilizes debugging.

Fixes: https://github.com/joyent/node/issues/8159
Refs: https://github.com/nodejs/io.js/pull/1524
PR-URL: https://github.com/nodejs/io.js/pull/1949
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Oleg Elifantiev <oleg@elifantiev.ru>
8 years agobuffer: fix case of one buffer passed to concat
Sakthipriyan Vairamani [Wed, 10 Jun 2015 17:06:15 +0000 (11:06 -0600)]
buffer: fix case of one buffer passed to concat

Fix Buffer.concat() so a copy is always returned regardless of the
number of buffers that were passed.

Previously if the array length was one then the same same buffer was
returned. This created a special case for the user where there was a
chance mutating the buffer returned by .concat() could mutate the buffer
passed in.

Also fixes an inconsistency when throwing if an array member was not a
Buffer instance. For example:

    Buffer.concat([42]);      // Returns 42
    Buffer.concat([42, 1]);  // Throws a TypeError

Now .concat() will always throw if an array member is not a Buffer
instance.

See: https://github.com/nodejs/io.js/issues/1891
PR-URL: https://github.com/nodejs/io.js/pull/1937
Reviewed-By: Trevor Norris <trev.norris@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
8 years agohttp_server: `prefinish` vs `finish`
Fedor Indutny [Mon, 13 Apr 2015 14:31:57 +0000 (16:31 +0200)]
http_server: `prefinish` vs `finish`

Do not detach the socket from the response until all data is actually
sent to the other side.

See: https://github.com/iojs/io.js/pull/1373
PR-URL: https://github.com/nodejs/io.js/pull/1411
Reviewed-By: Chris Dickinson <christopher.s.dickinson@gmail.com>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
8 years agodgram: make send cb act as "error" event handler
Matteo Collina [Tue, 26 May 2015 07:17:00 +0000 (09:17 +0200)]
dgram: make send cb act as "error" event handler

Modifies the dgram send() method to not emit errors when a DNS
lookup fails if there is a callback. Given that the same UDP
socket can be used to send messages to different hosts, the socket
can be reused even if one of those send() fails.

This slightly changes the behavior of a stable API, so that it behaves
as users would expect to.

This is based on https://github.com/joyent/node/pull/7738, which
landed in 77266d7fadd8dfefb107ccb1e3fe97f9620f1288.

Fixes: https://github.com/joyent/node/issues/4846
Refs: https://github.com/joyent/node/pull/7738
PR-URL: https://github.com/nodejs/io.js/pull/1796
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
8 years agodgram: make send cb act as "error" event handler
Chris Dickinson [Thu, 5 Jun 2014 19:42:41 +0000 (12:42 -0700)]
dgram: make send cb act as "error" event handler

This allows users to provide a callback that handles potential
errors resulting from a `socket.send` call. The original behavior
of emitting the error event on the socket is preserved.

Fixes: https://github.com/joyent/node/issues/4846
PR-URL: https://github.com/joyent/node/pull/7738
PR-URL: https://github.com/nodejs/io.js/pull/1796
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
8 years agovm: fix symbol access
Domenic Denicola [Mon, 1 Jun 2015 16:22:19 +0000 (12:22 -0400)]
vm: fix symbol access

By using the new SetHandler API instead of SetNamedPropertyHandler, we can
intercept symbols now. This forces us to use Maybes and MaybeLocals more,
since this new API does not have a non-maybe variant.

Fixes: https://github.com/nodejs/io.js/issues/884
PR-URL: https://github.com/nodejs/io.js/pull/1773
Reviewed-By: Fedor Indutny <fedor@indutny.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
8 years agovm: remove unnecessary access checks
Domenic Denicola [Sat, 23 May 2015 00:02:20 +0000 (20:02 -0400)]
vm: remove unnecessary access checks

No reason to install access checks if they're always going to return
true.

PR-URL: https://github.com/nodejs/io.js/pull/1773
Reviewed-By: Fedor Indutny <fedor@indutny.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
8 years agovm: fix property descriptors of sandbox properties
Domenic Denicola [Fri, 22 May 2015 23:41:28 +0000 (19:41 -0400)]
vm: fix property descriptors of sandbox properties

The GlobalPropertyQueryCallback was changed in 2010 to return an
integer instead of a boolean:

https://groups.google.com/forum/#!topic/v8-users/OOjHJrix-cU

This integer communicates the property descriptors of the property,
instead of just its presence or absence. However, the original
contextify code was probably written before this change, and it was
not updated when porting to Node.js.

Credit to @smikes for the test and the original PR of #885.

Fixes: https://github.com/nodejs/io.js/pull/864
Fixes: https://github.com/nodejs/io.js/pull/885
PR-URL: https://github.com/nodejs/io.js/pull/1773
Reviewed-By: Fedor Indutny <fedor@indutny.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
8 years agocrypto: remove kMaxLength on randomBytes()
Trevor Norris [Tue, 2 Jun 2015 19:10:47 +0000 (13:10 -0600)]
crypto: remove kMaxLength on randomBytes()

New Buffer implementation allows greater than kMaxLength to be created.
So instead check if the passed value is a valid Smi.

PR-URL: https://github.com/nodejs/io.js/pull/1825
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
8 years agobuffer: make additional changes to native API
Trevor Norris [Tue, 2 Jun 2015 18:53:30 +0000 (12:53 -0600)]
buffer: make additional changes to native API

Address comments and deprecations left in source files. These changes
include:

* Remove the deprecated API.
* Change Buffer::New() that did a copy of the data to Buffer::Copy()
* Change Buffer::Use() to Buffer::New()

PR-URL: https://github.com/nodejs/io.js/pull/1825
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
8 years agobuffer: switch API to return MaybeLocal<T>
Trevor Norris [Tue, 2 Jun 2015 17:09:03 +0000 (11:09 -0600)]
buffer: switch API to return MaybeLocal<T>

Instead of aborting in case of internal failure, return an empty
Local<Object>. Using the MaybeLocal<T> API, users must check their
return values.

PR-URL: https://github.com/nodejs/io.js/pull/1825
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
8 years agobuffer: switch to using Maybe<T> API
Trevor Norris [Tue, 2 Jun 2015 16:18:01 +0000 (10:18 -0600)]
buffer: switch to using Maybe<T> API

Use the new Maybe<T> syntax for v8::Object::SetPrototype().

PR-URL: https://github.com/nodejs/io.js/pull/1825
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
8 years agobuffer: finish implementing FreeCallback
Trevor Norris [Mon, 1 Jun 2015 18:29:17 +0000 (12:29 -0600)]
buffer: finish implementing FreeCallback

Passing a FreeCallback to Buffer::New() now uses externalized
ArrayBuffer's.

PR-URL: https://github.com/nodejs/io.js/pull/1825
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
8 years agobuffer: implement Uint8Array backed Buffer
Trevor Norris [Tue, 26 May 2015 18:42:14 +0000 (12:42 -0600)]
buffer: implement Uint8Array backed Buffer

With V8 4.4 removing the external array data API currently used by
Buffer, the new implementation uses the Uint8Array to back Buffer.

Buffers now have a maximum size of Smi::kMaxLength, as defined by V8.
Which is ~2 GB on 64 bit and ~1 GB on 32 bit.

The flag --use-old-buffer allows using the old Buffer implementation.
This flag will be removed once V8 4.4 has landed.

The two JS Buffer implementations have been split into two files for
simplicity.

Use getter to return expected .parent/.offset values for backwards
compatibility.

PR-URL: https://github.com/nodejs/io.js/pull/1825
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
8 years agobuffer: allow ARGS_THIS to accept a name
Trevor Norris [Tue, 26 May 2015 20:34:12 +0000 (14:34 -0600)]
buffer: allow ARGS_THIS to accept a name

Allowing the name to be passed to the ARGS_THIS macro will make it
easier to share code with the Uint8Array implementation.

PR-URL: https://github.com/nodejs/io.js/pull/1825
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
8 years agodeps: backport 7b24219346 from v8 upstream
Rod Vagg [Wed, 27 May 2015 00:34:17 +0000 (10:34 +1000)]
deps: backport 7b24219346 from v8 upstream

Original:
Fix lookup iterator checks in GetRealNamedProperty* methods

BUG=v8:4143
R=verwaest@chromium.org
LOG=n

Review URL: https://codereview.chromium.org/1161553004

Cr-Commit-Position: refs/heads/master@{#28616}

PR-URL: https://github.com/nodejs/io.js/pull/1805
Reviewed-By: Domenic Denicola <domenic@domenicdenicola.com>
8 years agonet: do not set V4MAPPED on FreeBSD
Julien Gilli [Mon, 2 Mar 2015 23:50:25 +0000 (15:50 -0800)]
net: do not set V4MAPPED on FreeBSD

V4MAPPED is not supported on recent FreeBSD versions, at least on 10.1.
Thus, do not set this flag in net.connect on FreeBSD.

Fixes: https://github.com/joyent/node/issues/8540
Fixes: https://github.com/joyent/node/issues/9204
PR-URL: https://github.com/joyent/node/pull/18204
PR-URL: https://github.com/iojs/io.js/pull/1555
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Fedor Indutny <fedor@indutny.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
8 years agoRevert "dns: remove AI_V4MAPPED hint flag on FreeBSD"
cjihrig [Wed, 29 Apr 2015 00:49:15 +0000 (20:49 -0400)]
Revert "dns: remove AI_V4MAPPED hint flag on FreeBSD"

This reverts commit 04bea9f9c224d9f863f671a1ad52a3f392b292cb.

PR-URL: https://github.com/iojs/io.js/pull/1555
Reviewed-By: Fedor Indutny <fedor@indutny.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
8 years agodoc: update v8 flags in man page
Michaël Zasso [Thu, 14 May 2015 09:12:17 +0000 (11:12 +0200)]
doc: update v8 flags in man page

PR-URL: https://github.com/iojs/io.js/pull/1701
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
8 years agodeps: update v8 to 4.3.61.21
Chris Dickinson [Tue, 5 May 2015 20:48:55 +0000 (13:48 -0700)]
deps: update v8 to 4.3.61.21

* @indutny's SealHandleScope patch (484bebc38319fc7c622478037922ad73b2edcbf9)
  has been cherry picked onto the top of V8 to make it compile.
* There's some test breakage in contextify.
* This was merged at the request of the TC.

PR-URL: https://github.com/iojs/io.js/pull/1632

8 years agotest: remove obsolete harmony flags
Chris Dickinson [Tue, 5 May 2015 01:16:54 +0000 (18:16 -0700)]
test: remove obsolete harmony flags

8 years agodoc,test: documents behaviour of non-existent file
Sakthipriyan Vairamani [Sun, 12 Jul 2015 16:58:50 +0000 (16:58 +0000)]
doc,test: documents behaviour of non-existent file

As per the discussion in
https://github.com/nodejs/io.js/pull/2093#discussion_r34343965, this
patch documents the behavior of calling fs.watchFile() with a path that
does not yet exist.

This patch also includes a test which checks if a file not present, the
callback is invoked at least once and if the file is created after
the callback is invoked, it will be invoked again with new stat
objects.

PR-URL: https://github.com/nodejs/io.js/pull/2169
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Brendan Ashworth <brendan.ashworth@me.com>
8 years agorepl: don't clobber RegExp.$ properties
Sakthipriyan Vairamani [Wed, 8 Jul 2015 21:53:48 +0000 (03:23 +0530)]
repl: don't clobber RegExp.$ properties

In REPL, if we evaluate the `RegExp` object's predefined properties,
and if they happen to have the same expression, for example,

    > RegExp.$1
    'RegExp.$1'

then doing `eval(RegExp.$1)` would evaluate `RegExp.$1` recursively and
eventually throw `RangeError: Maximum call stack size exceeded`.

This patch stores the old values of `RegExp`'s predefined proprties in
an array and restores them just before the current expression entered
by user is evaluated.

Fixes: https://github.com/nodejs/io.js/issues/597
PR-URL: https://github.com/nodejs/io.js/pull/2137
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
8 years agotest: change the hostname to an invalid name
Sakthipriyan Vairamani [Sun, 2 Aug 2015 11:54:40 +0000 (17:24 +0530)]
test: change the hostname to an invalid name

In my Ubuntu 14.04.2 LTS machine, it tries to resolve the name
'blah.blah' and it fails with ETIMEOUT instead of ENOTFOUND. This patch
changes the hostname to "...", an invalid name, so that it will fail
immediately.

PR-URL: https://github.com/nodejs/io.js/pull/2287
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Evan Lucas <evanlucas@me.com>
8 years agotest: fix messages and use return to skip tests
Sakthipriyan Vairamani [Sun, 2 Aug 2015 14:06:43 +0000 (19:36 +0530)]
test: fix messages and use return to skip tests

This is a followup of https://github.com/nodejs/io.js/pull/2109.
The tests which didn't make it in #2109, are included in this patch.
The skip messages are supposed to follow the format

    1..0 # Skipped: [Actual reason why the test is skipped]

and the tests should be skipped with the return statement.

PR-URL: https://github.com/nodejs/io.js/pull/2290
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
Reviewed-By: Johan Bergström <bugs@bergstroem.nu>
9 years agowin,node-gyp: enable delay-load hook by default
Bert Belder [Wed, 15 Apr 2015 20:58:50 +0000 (13:58 -0700)]
win,node-gyp: enable delay-load hook by default

The delay-load hook allows node.exe/iojs.exe to be renamed. See efadffe
for more background.

PR-URL: https://github.com/iojs/io.js/pull/1433
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
9 years agodeps: make node-gyp work with io.js
cjihrig [Fri, 27 Feb 2015 18:40:58 +0000 (13:40 -0500)]
deps: make node-gyp work with io.js

Every npm version bump requires a few patches to be floated on
node-gyp for io.js compatibility. These patches are found in
03d199276e21c1fa08d8df14eeb654c90cc5aa20,
5de334c23096492014a097ff487f07ad8eaee6d2, and
da730c76e98fb9fd18dac445dafbbec74d79f802. This commit squashes
them into a single commit.

PR-URL: https://github.com/iojs/io.js/pull/990
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
9 years agodeps: upgrade to npm 2.13.3
Kat Marchán [Sat, 1 Aug 2015 00:08:03 +0000 (17:08 -0700)]
deps: upgrade to npm 2.13.3

PR-URL: https://github.com/nodejs/io.js/pull/2284
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
9 years agotest: use common.isWindows consistently
Sakthipriyan Vairamani [Wed, 29 Jul 2015 11:48:04 +0000 (17:18 +0530)]
test: use common.isWindows consistently

In the tests, we use "process.platform === 'win32'" in some places.
This patch replaces them with the "common.isWindows" for consistency.

PR-URL: https://github.com/nodejs/io.js/pull/2269
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
9 years agocluster: add handle ref/unref stubs in rr mode
Ben Noordhuis [Wed, 29 Jul 2015 23:05:11 +0000 (01:05 +0200)]
cluster: add handle ref/unref stubs in rr mode

Add ref() and unref() stub methods to the faux handle in round-robin
mode.  Fixes the following TypeError when calling `server.unref()` in
the worker:

    net.js:1521
        this._handle.unref();
                     ^
    TypeError: this._handle.unref is not a function
        at Server.unref (net.js:1521:18)

No actual reference counting is implemented.  It would effectively be
a no-op because the control channel would still keep the worker alive.

Fixes: https://github.com/nodejs/node/issues/73
PR-URL: https://github.com/nodejs/io.js/pull/2274
Reviewed-By: Evan Lucas <evanlucas@me.com>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
9 years agotools: expose skip output to test runner
Johan Bergström [Wed, 8 Jul 2015 00:37:43 +0000 (10:37 +1000)]
tools: expose skip output to test runner

In the TAP protocol, skips are flagged as ok. Expose more
information so we can understand if the test was skipped or not.

PR-URL: https://github.com/nodejs/io.js/pull/2130
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
9 years agobuild: produce symbol map files on windows
Ali Ijaz Sheikh [Sat, 25 Jul 2015 00:59:14 +0000 (17:59 -0700)]
build: produce symbol map files on windows

This produces map files as part of the build on windows. The existence of
these files enable profiling and tick-processing using the --prof command
line.
See: https://github.com/nodejs/io.js/pull/2090#issuecomment-124746673

Map files are documented here:
https://msdn.microsoft.com/en-us/library/k7xkk3e2.aspx

PR-URL: https://github.com/nodejs/io.js/pull/2243
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
9 years agotest: fix fs.readFile('/dev/stdin') tests
Ben Noordhuis [Wed, 29 Jul 2015 00:30:28 +0000 (02:30 +0200)]
test: fix fs.readFile('/dev/stdin') tests

The tests were creating the temp fixture file in both the parent
and the child process, leading to interesting race conditions on
the slower buildbots.

Rod notes that the tests started failing after putting the build
directory on a NFS mount.

Fixes: https://github.com/nodejs/io.js/issues/2261
PR-URL: https://github.com/nodejs/io.js/pull/2265
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
Reviewed-By: Rod Vagg <rod@vagg.org>
9 years agodoc: properly inheriting from EventEmitter
Sakthipriyan Vairamani [Sun, 12 Jul 2015 16:10:57 +0000 (16:10 +0000)]
doc: properly inheriting from EventEmitter

There are so many buggy code out there, just because not inheriting
properly from `EventEmitter`. This patch gives an official
recommendation.

PR-URL: https://github.com/nodejs/io.js/pull/2168
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
Reviewed-By: Michaël Zasso <mic.besace@gmail.com>
9 years agodoc: a listener, not "an" listener
Sam Roberts [Tue, 28 Jul 2015 04:00:32 +0000 (21:00 -0700)]
doc: a listener, not "an" listener

Reviewed-By: Sam Roberts <vieuxtech@gmail.com>
Reviewed-By: Trevor Norris <trev.norris@gmail.com>
PR-URL: https://github.com/nodejs/io.js/pull/1025

9 years agodoc: server close event does not have an argument
Sam Roberts [Mon, 2 Mar 2015 20:22:43 +0000 (12:22 -0800)]
doc: server close event does not have an argument

Reviewed-By: Sam Roberts <vieuxtech@gmail.com>
Reviewed-By: Trevor Norris <trev.norris@gmail.com>
PR-URL: https://github.com/nodejs/io.js/pull/1025

9 years agoWorking on v2.5.1
cjihrig [Tue, 28 Jul 2015 15:22:31 +0000 (11:22 -0400)]
Working on v2.5.1

PR-URL: https://github.com/nodejs/io.js/pull/2239

9 years ago2015-07-28 io.js v2.5.0 Release v2.5.0
cjihrig [Tue, 28 Jul 2015 14:59:14 +0000 (10:59 -0400)]
2015-07-28 io.js v2.5.0 Release

Notable changes

* **https**: TLS sessions in Agent are reused (Fedor Indutny)
https://github.com/nodejs/io.js/pull/2228.
* **src**: base64 decoding is now 50% faster (Ben Noordhuis)
https://github.com/nodejs/io.js/pull/2193.
* **npm**: Upgraded to v2.13.2, release notes can be found in
<https://github.com/npm/npm/releases/tag/v2.13.2> (Kat Marchán)
https://github.com/nodejs/io.js/pull/2241.

PR-URL: https://github.com/nodejs/io.js/issues/2239

9 years agoutil: delay creation of debug context
Ali Ijaz Sheikh [Sat, 25 Jul 2015 13:01:24 +0000 (06:01 -0700)]
util: delay creation of debug context

We need the debug context to be able to inspect promises. However, this is
very expensive and should not be done on default startup.

PR-URL: https://github.com/nodejs/io.js/pull/2248
Reviewed-By: Brian White <mscdex@mscdex.net>
Reviewed-By: Michaël Zasso <mic.besace@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Christopher Monsanto <chris@monsan.to>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
9 years agotest: do not use public IPs for timeout testing
Rich Trott [Thu, 25 Jun 2015 06:33:11 +0000 (23:33 -0700)]
test: do not use public IPs for timeout testing

PR-URL: https://github.com/nodejs/io.js/pull/2057
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
9 years agotimers: improve Timer.now() performance
Ben Noordhuis [Mon, 27 Jul 2015 21:29:03 +0000 (23:29 +0200)]
timers: improve Timer.now() performance

Record the start time so we can make the return value of Timer.now()
relative to it, increasing the chances that it fits in a tagged integer
instead of a heap-allocated double, at least for the first one or two
billion milliseconds.

PR-URL: https://github.com/nodejs/io.js/pull/2256
Reviewed-By: Trevor Norris <trev.norris@gmail.com>
9 years agotimers: remove unused Timer.again()
Ben Noordhuis [Mon, 27 Jul 2015 21:12:42 +0000 (23:12 +0200)]
timers: remove unused Timer.again()

PR-URL: https://github.com/nodejs/io.js/pull/2256
Reviewed-By: Trevor Norris <trev.norris@gmail.com>
9 years agotimers: remove unused Timer.getRepeat()
Ben Noordhuis [Mon, 27 Jul 2015 21:12:00 +0000 (23:12 +0200)]
timers: remove unused Timer.getRepeat()

PR-URL: https://github.com/nodejs/io.js/pull/2256
Reviewed-By: Trevor Norris <trev.norris@gmail.com>
9 years agotimers: remove unused Timer.setRepeat()
Ben Noordhuis [Mon, 27 Jul 2015 21:11:19 +0000 (23:11 +0200)]
timers: remove unused Timer.setRepeat()

PR-URL: https://github.com/nodejs/io.js/pull/2256
Reviewed-By: Trevor Norris <trev.norris@gmail.com>
9 years agonet: don't throw on immediately destroyed socket
Evan Lucas [Mon, 27 Jul 2015 00:24:28 +0000 (19:24 -0500)]
net: don't throw on immediately destroyed socket

Fixes regression introduced in af249fa8a15bad8996187e73b480b30dcd881bad.

With connect being deferred to the next tick, Socket.destroy could be
called before connect. Socket.destroy sets _connecting to false which
would cause an assertion error.

Fixes: https://github.com/nodejs/io.js/issues/2250
PR-URL: https://github.com/nodejs/io.js/pull/2251
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
9 years agohttps: reuse TLS sessions in Agent
Fedor Indutny [Thu, 23 Jul 2015 04:18:38 +0000 (21:18 -0700)]
https: reuse TLS sessions in Agent

Fix: #1499
PR-URL: https://github.com/nodejs/io.js/pull/2228
Reviewed-By: Shigeki Ohtsu <ohtsu@iij.ad.jp>
Reviewed-By: Trevor Norris <trev.norris@gmail.com>
9 years agotest: skip IPv6 part before testing it
Sakthipriyan Vairamani [Wed, 22 Jul 2015 19:58:30 +0000 (01:28 +0530)]
test: skip IPv6 part before testing it

PR-URL: https://github.com/nodejs/io.js/pull/2226
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Roman Reiss <me@silverwind.io>
9 years agonode: remove bad fn call and check
Trevor Norris [Fri, 10 Jul 2015 19:55:14 +0000 (13:55 -0600)]
node: remove bad fn call and check

These two lines exist because of a screw up on my part while combining
MakeCallback() and MakeDomainCallback().

The reason it never broke core tests is because any paths it would have
broken were rerouted to AsyncWrap::MakeCallback(). The only case that
node::MakeCallback() handles anymore is setImmediate().

Fix: a1da024 "node, async-wrap: remove MakeDomainCallback"
PR-URL: https://github.com/nodejs/io.js/pull/2157
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
9 years agobenchmark: add remaining path benchmarks & optimize
Nathan Woltman [Sat, 4 Jul 2015 19:50:07 +0000 (15:50 -0400)]
benchmark: add remaining path benchmarks & optimize

As a follow-up to 0d15161, this commit adds benchmarks for the rest
of the path functions and also forces V8 to optimize the functions
before starting the benchmark test.

PR-URL: https://github.com/nodejs/io.js/pull/2103
Reviewed-By: Brendan Ashworth <brendan.ashworth@me.com>
9 years agotest: fix valgrind uninitialized memory warning
Ben Noordhuis [Thu, 16 Jul 2015 09:17:22 +0000 (11:17 +0200)]
test: fix valgrind uninitialized memory warning

parallel/test-buffer called `Buffer.prototype.toString()` on a buffer
with uninitialized memory.  Call `Buffer.prototype.fill()` on it first.

PR-URL: https://github.com/nodejs/io.js/pull/2193
Reviewed-By: Trevor Norris <trev.norris@gmail.com>
9 years agosrc: make base64 decoding 50% faster
Ben Noordhuis [Wed, 15 Jul 2015 20:09:52 +0000 (22:09 +0200)]
src: make base64 decoding 50% faster

Make the inner loop execute fewer compare-and-branch executions per
processed byte, resulting in a 50% or more speedup.

This coincidentally fixes an out-of-bounds read:

    while (unbase64(*src) < 0 && src < srcEnd)

Should have read:

    while (src < srcEnd && unbase64(*src) < 0)

But this commit removes the offending code altogether.

Fixes: https://github.com/nodejs/io.js/issues/2166
PR-URL: https://github.com/nodejs/io.js/pull/2193
Reviewed-By: Trevor Norris <trev.norris@gmail.com>
9 years agowin,node-gyp: enable delay-load hook by default
Bert Belder [Wed, 15 Apr 2015 20:58:50 +0000 (13:58 -0700)]
win,node-gyp: enable delay-load hook by default

The delay-load hook allows node.exe/iojs.exe to be renamed. See efadffe
for more background.

PR-URL: https://github.com/iojs/io.js/pull/1433
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
9 years agodeps: make node-gyp work with io.js
cjihrig [Fri, 27 Feb 2015 18:40:58 +0000 (13:40 -0500)]
deps: make node-gyp work with io.js

Every npm version bump requires a few patches to be floated on
node-gyp for io.js compatibility. These patches are found in
03d199276e21c1fa08d8df14eeb654c90cc5aa20,
5de334c23096492014a097ff487f07ad8eaee6d2, and
da730c76e98fb9fd18dac445dafbbec74d79f802. This commit squashes
them into a single commit.

PR-URL: https://github.com/iojs/io.js/pull/990
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
9 years agodeps: upgrade to npm 2.13.2
Kat Marchán [Fri, 24 Jul 2015 22:09:52 +0000 (15:09 -0700)]
deps: upgrade to npm 2.13.2

PR-URL: https://github.com/nodejs/io.js/pull/2241
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
9 years agotools: use local or specified $NODE for test-npm
Jeremiah Senkpiel [Mon, 15 Jun 2015 16:10:44 +0000 (09:10 -0700)]
tools: use local or specified $NODE for test-npm

PR-URL: https://github.com/nodejs/io.js/pull/1984
Reviewed-By: Johan Bergström <bugs@bergstroem.nu>
Reviewed-By: Roman Reiss <me@silverwind.io>
9 years agorepl: better empty line handling
Sakthipriyan Vairamani [Sun, 12 Jul 2015 21:48:50 +0000 (21:48 +0000)]
repl: better empty line handling

In REPL, if we try to evaluate an empty line, we get `undefined`.

    > process.version
    'v2.3.4'
    >
    undefined
    >
    undefined
    >

This patch prevents `undefined` from printing if the string is empty.

    > process.version
    'v2.3.5-pre'
    >
    >
    >

PR-URL: https://github.com/nodejs/io.js/pull/2163
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
9 years agorepl: improving line continuation handling
Sakthipriyan Vairamani [Sun, 12 Jul 2015 01:22:33 +0000 (01:22 +0000)]
repl: improving line continuation handling

As it is, REPL doesn't honour the line continuation feature very well.
This patch

 1. keeps track of the beginning of the string literals and if they
    don't end or current line doesn't end with line continuation, then
    error out.

 2. monitors if the line continuation character is used without the
    string literal and errors out if that happens.

PR-URL: https://github.com/nodejs/io.js/pull/2163
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
9 years agorepl: preventing REPL crash with inherited properties
Sakthipriyan Vairamani [Sun, 12 Jul 2015 00:58:20 +0000 (00:58 +0000)]
repl: preventing REPL crash with inherited properties

When an inherited property is used as a REPL keyword, the REPL crashes.

    ➜  Desktop  iojs
    > process.version
    'v2.3.4'
    > .toString
    readline.js:913
            stream[ESCAPE_DECODER].next(r[i]);
                                    ^
    TypeError: Cannot read property 'call' of undefined
        at REPLServer.parseREPLKeyword (repl.js:746:15)
        at REPLServer.<anonymous> (repl.js:284:16)
        at emitOne (events.js:77:13)
        at REPLServer.emit (events.js:169:7)
        at REPLServer.Interface._onLine (readline.js:210:10)
        at REPLServer.Interface._line (readline.js:549:8)
        at REPLServer.Interface._ttyWrite (readline.js:826:14)
        at ReadStream.onkeypress (readline.js:105:10)
        at emitTwo (events.js:87:13)
        at ReadStream.emit (events.js:172:7)
    ➜  Desktop

This patch makes the internal `commands` object inherit from `null` so
that there will be no inherited properties.

    > process.version
    'v2.3.5-pre'
    > .toString
    Invalid REPL keyword
    >

PR-URL: https://github.com/nodejs/io.js/pull/2163
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
9 years agorepl: fixing `undefined` in invalid REPL keyword error
Sakthipriyan Vairamani [Sun, 12 Jul 2015 00:53:39 +0000 (00:53 +0000)]
repl: fixing `undefined` in invalid REPL keyword error

When an invalid REPL keyword is used, we actually print `undefined` as
well in the console.

    > process.version
    'v2.3.4'
    > .invalid_repl_command
    Invalid REPL keyword
    undefined
    >

This patch prevents printing `undefined` in this case.

    > process.version
    'v2.3.5-pre'
    > .invalid_repl_command
    Invalid REPL keyword
    >

PR-URL: https://github.com/nodejs/io.js/pull/2163
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
9 years agodoc: add GPG fingerprint for cjihrig
cjihrig [Tue, 21 Jul 2015 18:37:36 +0000 (14:37 -0400)]
doc: add GPG fingerprint for cjihrig

PR-URL: https://github.com/nodejs/io.js/pull/2217
Reviewed-By: Rod Vagg <rod@vagg.org>
9 years agodoc: note about custom inspect functions
Sakthipriyan Vairamani [Thu, 9 Jul 2015 18:54:21 +0000 (18:54 +0000)]
doc: note about custom inspect functions

See: https://github.com/nodejs/io.js/issues/1798

When an Object is printed in REPL, the actual representation can be
overriden by defining `inspect` method on the objects. This patch
includes a note about the same in the REPL documentation.

PR-URL: https://github.com/nodejs/io.js/pull/2142
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Michaël Zasso <mic.besace@gmail.com>
9 years agodeps: update V8 to 4.2.77.21
Ali Ijaz Sheikh [Fri, 24 Jul 2015 14:49:12 +0000 (07:49 -0700)]
deps: update V8 to 4.2.77.21

Picks up the latest patch-release on the V8 4.2 branch.
https://codereview.chromium.org/1156323004

PR-URL: https://github.com/nodejs/io.js/issues/2238
Fixes: https://github.com/nodejs/io.js/issues/2235
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
9 years agoprocess: resize stderr on SIGWINCH
Jeremiah Senkpiel [Thu, 23 Jul 2015 16:15:19 +0000 (09:15 -0700)]
process: resize stderr on SIGWINCH

Fixes: https://github.com/nodejs/io.js/issues/2219
PR-URL: https://github.com/nodejs/io.js/pull/2231
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
Reviewed-By: Michaël Zasso <mic.besace@gmail.com>
9 years agocluster: emit 'message' event on cluster master
Sam Roberts [Sun, 15 Feb 2015 02:50:56 +0000 (18:50 -0800)]
cluster: emit 'message' event on cluster master

For consistency with the worker 'exit', 'online', 'disconnect', and
'listening' events which are emitted on worker and cluster, also emit
'message' on cluster.

Reviewed-by: Sam Roberts <vieuxtech@gmail.com>
Reviewed-by: Christian Tellnes <christian@tellnes.no>
Reviewed-by: Stephen Belanger <admin@stephenbelanger.com>
PR-URL: https://github.com/nodejs/io.js/pull/861

9 years agotls: add `getTicketKeys()`/`setTicketKeys()`
Fedor Indutny [Wed, 22 Jul 2015 20:52:23 +0000 (13:52 -0700)]
tls: add `getTicketKeys()`/`setTicketKeys()`

Introduce two new APIs for getting/settings the TLS Server Ticket Keys.

Fix: #1465
PR-URL: https://github.com/nodejs/io.js/pull/2227
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
9 years agodoc: Replace util.debug with console.error
Yosuke Furukawa [Tue, 21 Jul 2015 17:30:20 +0000 (02:30 +0900)]
doc: Replace util.debug with console.error

PR-URL: https://github.com/nodejs/io.js/pull/2214
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
9 years agocrypto: fix legacy SNICallback
Fedor Indutny [Sun, 17 May 2015 13:10:24 +0000 (15:10 +0200)]
crypto: fix legacy SNICallback

`onselect` is set on the `sniObject_` not on the `Connection` instance.

See: https://github.com/joyent/node/pull/25109
PR-URL: https://github.com/nodejs/io.js/pull/1720
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
9 years agohttp: Check this.connection before using it
Sakthipriyan Vairamani [Mon, 13 Jul 2015 19:38:25 +0000 (01:08 +0530)]
http: Check this.connection before using it

Refer: https://github.com/joyent/node/pull/25670

PR-URL: https://github.com/nodejs/io.js/pull/2172
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Brendan Ashworth <brendan.ashworth@me.com>
9 years agotest: add -no_rand_screen to s_client opts on Win
Shigeki Ohtsu [Sat, 18 Jul 2015 02:59:55 +0000 (11:59 +0900)]
test: add -no_rand_screen to s_client opts on Win

RAND_screen() causes stability issues in invoking openssl-cli s_client
on win2008r2 in CI. Disable to use it by adding -no_rand_screen
options to all tls tests that use common.opensslCli.

Fixes: https://github.com/nodejs/io.js/issues/2150
PR-URL: https://github.com/nodejs/io.js/pull/2209
Reviewed-By: Rod Vagg <rod@vagg.org>
Reviewed-By: Joao Reis <reis@janeasystems.com>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
9 years agowin,node-gyp: enable delay-load hook by default
Bert Belder [Wed, 15 Apr 2015 20:58:50 +0000 (13:58 -0700)]
win,node-gyp: enable delay-load hook by default

The delay-load hook allows node.exe/iojs.exe to be renamed. See efadffe
for more background.

PR-URL: https://github.com/iojs/io.js/pull/1433
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
9 years agodeps: make node-gyp work with io.js
cjihrig [Fri, 27 Feb 2015 18:40:58 +0000 (13:40 -0500)]
deps: make node-gyp work with io.js

Every npm version bump requires a few patches to be floated on
node-gyp for io.js compatibility. These patches are found in
03d199276e21c1fa08d8df14eeb654c90cc5aa20,
5de334c23096492014a097ff487f07ad8eaee6d2, and
da730c76e98fb9fd18dac445dafbbec74d79f802. This commit squashes
them into a single commit.

PR-URL: https://github.com/iojs/io.js/pull/990
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
9 years agodeps: upgrade to npm 2.13.1
Kat Marchán [Tue, 21 Jul 2015 03:07:07 +0000 (20:07 -0700)]
deps: upgrade to npm 2.13.1

PR-URL: https://github.com/nodejs/io.js/pull/2210
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>