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

10665 Commits

Author SHA1 Message Date
Ben Noordhuis
dd260d2152 test: fix make test-addons target
I broke the python script in commit edaf7af but because test-all does
not run test-addons, it slipped under the radar.  Mea culpa.

Fixes the following test runner error:

    Traceback (most recent call last):
      File "tools/test.py", line 1522, in <module>
        sys.exit(Main())
      File "tools/test.py", line 1454, in Main
        test_list = root.ListTests([], path, context, arch, mode)
      File "tools/test.py", line 720, in ListTests
        test.AddTestsToList(result, full_path, path, context, arch, mode)
      File "tools/test.py", line 690, in AddTestsToList
        arch, mode)
      File "/home/bnoordhuis/src/v1.x/test/gc/../testpy/__init__.py", line 176, in ListTests
        result.append(SimpleTestCase(test, file_path, mode, self.context, self))
    TypeError: __init__() takes at least 7 arguments (6 given)

PR-URL: https://github.com/iojs/io.js/pull/313
Reviewed-By: Chris Dickinson <christopher.s.dickinson@gmail.com>
2015-01-12 23:21:51 +01:00
Steven Rockarts
e431cae7e7 win,msi: create npm folder in AppData directory
Create the empty npm folder in Roaming\Appdata so that non-Administrator
users have a place to store global packages. This fixes the error Error:
ENOENT, stat error that occurs when a user tries to run the npm install
<package> command.

Bug: https://github.com/joyent/node/issues/8141
PR: https://github.com/joyent/node/pull/8838
Reviewed-by: Bert Belder <bertbelder@gmail.com>

Please enter the commit message for your changes. Lines starting
2015-01-12 23:06:29 +01:00
Ben Noordhuis
42ebdcbff1 addon: update NODE_MODULE_VERSION macro
io.js v1.0.0 is not ABI-compatible with joyent/node@v0.12, update
the NODE_MODULE_VERSION macro to reflect that.  Update to a much
larger value to avoid future clashes with joyent/node.

PR-URL: https://github.com/iojs/io.js/pull/312
Reviewed-By: Bert Belder <bertbelder@gmail.com>
2015-01-12 22:37:45 +01:00
Chris Dickinson
9120f2b1fd doc: update style for iojs
* updates the styling for the iojs docs
* pulls the processing step for markdown files into
  a separate module
* adds the ability to insert comments into the markdown

PR-URL: https://github.com/iojs/io.js/pull/297
Fixes: https://github.com/iojs/iojs.github.io/issues/23
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
2015-01-12 13:44:50 -08:00
cjihrig
3a85eac4ec fs: undeprecate exists() and existsSync()
fs.exists() and fs.existsSync() were deprecated in #103. This
commit removes the deprecation message, in order to stay more
in sync with joyent/node for the io.js 1.0.0 release.

Fixes: https://github.com/iojs/io.js/issues/257
PR-URL: https://github.com/iojs/io.js/pull/307
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Bert Belder <bertbelder@gmail.com>
2015-01-12 14:52:08 -05:00
cjihrig
14dc9175eb assert: throw when block is not a function
Currently, anything passed as the block argument to throws()
and doesNotThrow() is interpreted as a function, which can
lead to unexpected results. This commit checks the type of
block, and throws a TypeError if it is not a function.

Fixes: https://github.com/iojs/io.js/issues/275
PR-URL: https://github.com/iojs/io.js/pull/308
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2015-01-12 14:10:33 -05:00
Fedor Indutny
7c4a50dd2f gyp: remove vanished masm file from openssl build
PR-URL: https://github.com/iojs/io.js/pull/289
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2015-01-12 21:31:09 +03:00
Fedor Indutny
a76811c811 test: fix crypto-stream after openssl update
PR-URL: https://github.com/iojs/io.js/pull/289
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2015-01-12 21:31:09 +03:00
Fedor Indutny
ced41b07dd openssl: fix build failure on windows
Backport of: https://github.com/openssl/openssl/commit/5c5e7e

Original commit message:

    Fix build failure on Windows due to undefined cflags identifier

    Reviewed-by: Tim Hudson <tjh@openssl.org>

PR-URL: https://github.com/iojs/io.js/pull/289
Reviewed-By: Fedor Indutny <fedor@indutny.com>
2015-01-12 21:31:08 +03:00
Fedor Indutny
b910613792 openssl: fix keypress requirement in apps on win32
Original source:

http://openssl.6102.n7.nabble.com/PATCH-s-client-Fix-keypress-requirement-with-redirected-input-on-Windows-td46787.html

Reviewed-By: Fedor Indutny <fedor@indutny.com>
2015-01-12 21:31:08 +03:00
Fedor Indutny
eebdf7ac85 deps: update openssl to 1.0.1k
PR-URL: https://github.com/iojs/io.js/pull/289
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2015-01-12 21:31:08 +03:00
Ben Noordhuis
c8676cb361 test: move sequential/test-debug-port-cluster
Move sequential/test-debug-port-cluster to test/parallel.  This test
is safe to run in parallel with other debugger tests, it doesn't use
fixed port numbers.

PR-URL: https://github.com/iojs/io.js/pull/306
Reviewed-By: Miroslav Bajtoš <miroslav@strongloop.com>
2015-01-12 18:31:34 +01:00
Ben Noordhuis
3da4f87b32 test: move sequential/test-debug-signal-cluster
Move sequential/test-debug-signal-cluster to test/parallel.  Per the
previous commit, it can now run in parallel with other debugger tests.

PR-URL: https://github.com/iojs/io.js/pull/306
Reviewed-By: Miroslav Bajtoš <miroslav@strongloop.com>
2015-01-12 18:31:31 +01:00
Ben Noordhuis
11c1bae734 lib: make --debug-port work with cluster
Make the cluster module intercept the `--debug-port=<port>` command line
switch and replace it with the debug port of the child process.

A happy coincidence of this change is that it finally makes it possible
to run the sequential/test-debug-signal-cluster in parallel, it now no
longer needs the default port numbers.

PR-URL: https://github.com/iojs/io.js/pull/306
Reviewed-By: Miroslav Bajtoš <miroslav@strongloop.com>
2015-01-12 18:31:29 +01:00
Ben Noordhuis
5ec5fd83d4 test: delete sequential/test-debug-cluster
The test does not work well with concurrent invocations of the test
runner because it uses fixed port numbers.  The functionality it tests
is covered by sequential/test-debug-port-cluster, a verbatim copy with
the only difference being that it doesn't use fixed port numbers.

PR-URL: https://github.com/iojs/io.js/pull/306
Reviewed-By: Miroslav Bajtoš <miroslav@strongloop.com>
2015-01-12 18:30:54 +01:00
Rod Vagg
f0c6fe53e1 doc: add TC meeting 2015-01-07 minutes
PR-URL: https://github.com/iojs/io.js/pull/248
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2015-01-12 22:32:07 +11:00
Rod Vagg
c52e43d97c doc: clarified & split up contribution docs
- clarified the role of "collaborators"
- split out a governance doc
- split out a collaborator guide
- cleaned up the contributing doc
- cleaned up the readme & added collaborators list

PR-URL: https://github.com/iojs/io.js/pull/233
Reviewed-By: Chris Dickinson <christopher.s.dickinson@gmail.com>
Reviewed-By: Mikeal Rogers <mikeal.rogers@gmail.com>

(Note: no explicit "LGTM" from Mikeal)

Discussed at TC meeting 2015-01-07, agreed to push further
amendments to governance to future PRs.
2015-01-12 22:24:33 +11:00
Ben Noordhuis
913addbff5 Revert "url: support path for url.format"
This reverts commit d312b6d15c.

Reverted for breaking `npm install` with git+ssh URLs.

Conflicts:
    doc/api/url.markdown

Fixes: https://github.com/iojs/io.js/issues/295
PR-URL: https://github.com/iojs/io.js/pull/303
Reviewed-By: Rod Vagg <rod@vagg.org>
2015-01-12 12:15:38 +01:00
Evan Lucas
a1e54d6fb7 url: fix parsing of ssh urls
Fix regression introduced in 6120472036
that broke parsing of some ssh: urls.

An example url is ssh://git@github.com:npm/npm.git

PR-URL: https://github.com/iojs/io.js/pull/299
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2015-01-12 10:56:41 +01:00
Rod Vagg
70c2501373 build: move armv6 snapshot test to configure_arm()
fails on windows because is_arch_armv6() calls CC to get properties,
so moved to a scope where we know we're at least on ARM

PR-URL: https://github.com/iojs/io.js/pull/296
Reviewed-By: Chris Dickinson <christopher.s.dickinson@gmail.com>
2015-01-12 16:05:15 +11:00
Cydox
0cca6fe74a build: Warn when using snapshot on Armv6
Building io.js on armv6 with snapshot enabled does not work due to a bug in v8,
so it now warns when building on armv6 and having snapshot enabled.

PR-URL: https://github.com/iojs/io.js/pull/282
Reviewed-By: Rod Vagg <rod@vagg.org>
2015-01-12 11:17:17 +11:00
Evan Lucas
d51efd07ac net: remove TODO for moving isIP to dns
It is not really DNS-specific so keeping it in net makes more sense.

PR-URL: https://github.com/iojs/io.js/pull/286
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2015-01-11 22:21:04 +01:00
Ben Noordhuis
26dd9e15bb build,src: remove sslv2 support
SSLv2 has been deprecated and known broken for nearly twenty years now.

I made SSLv2 support opt-in well over a year ago in commit 39aa894 and
now this commit removes it entirely.

PR-URL: https://github.com/iojs/io.js/pull/290
Reviewed-By: Fedor Indutny <fedor@indutny.com>
Reviewed-By: Rod Vagg <rod@vagg.org>
2015-01-11 16:07:45 +01:00
Rod Vagg
3ecad1d542 src: only append "-pre" to version if no tag
removed because nightly builds use the TAG make variable
to create a prerelease tag after the version yet `-pre` is
also appended beyond that. `-pre` is unnecessary if another
prerelease tag is being used.

Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2015-01-11 22:44:27 +11:00
Rod Vagg
2a6a9bad64 doc: remove changelog.html from doc make target
not essential for doc build and currently broken because
tools/build_changelog.sh requires ./node.

leaving as separate make target so it can be invoked
separately in future.

PR-URL: https://github.com/iojs/io.js/pull/285
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2015-01-11 22:39:24 +11:00
Ben Noordhuis
7e648da834 test: fix bad assumption in pummel/test-vm-memleak
pummel/test-vm-memleak is an old test that assumes the fairly
aggressive heuristics that were common with the old collector.

The current garbage collector has a more laissez-faire attitude.
Put an upper limit on the size of the old space and update the
test's expectations.

PR-URL: https://github.com/iojs/io.js/pull/280
Reviewed-By: Bert Belder <bertbelder@gmail.com>
2015-01-10 23:45:49 +01:00
Bert Belder
b57e9a9973 win,test: try again if file unlink fails
Now that parallel tests are enabled, the test runner spits out a ton of
'access denied' errors while running the tests. These happen because a
virus scanner or the indexing service temporarily open the file after it
has been updated, and the test runner tries to unlink() them at the same
time.

This patch resolves this issue by attempting to unlink the file until it
succeeds.

PR-URL: https://github.com/iojs/io.js/pull/284
Reviewed-by: Ben Noordhuis <info@bnoordhuis.nl>
2015-01-11 01:54:35 +01:00
Vladimir Kurchatkin
7f9a6c6213 fs: use ES6 octal literals for mode
Update docs, comments and code to use ES6 octal literals instead of
decimal + comment.

PR-URL: https://github.com/iojs/io.js/pull/281
Reviewed-by: Bert Belder <bertbelder@gmail.com>
Reviewed-by: Colin Ihrig <cjihrig@gmail.com>
2015-01-11 00:46:23 +01:00
Fedor Indutny
0d02515d6e zlib: do not unref() if wasn't ref()ed
In very unlikely case, where `deflateInit2()` may return error (right
now happening only on exhausting all memory), the `ZCtx::Error()` will
be called and will try to `Unref()` the handle. But the problem is that
this handle was never `Ref()`ed, so it will trigger an assertion error
and crash the program.

Reviewed-by: Ben Noordhuis <info@bnoordhuis.nl>
PR-URL: https://github.com/joyent/node/pull/8687

Cherry-picked-from: 8c868989be
2015-01-10 22:32:12 +01:00
Trevor Norris
4481cf7296 src: remove icu_config
ICU support in v0.12 generates a new icu_config.gypi. This was
accidentally committed after switching branches. The file has been removed
and added to .gitignore.

Cherry-picked-from: 813114dab0
2015-01-10 22:32:12 +01:00
Fedor Indutny
e92dbf3af9 src: check if NODE_WANT_INTERNALS is defined
Otherwise a warning could be printed on some systems.
This fixes joyent/node#8419.

Cherry-picked-from: d87ae24dfe
2015-01-10 22:32:11 +01:00
Julien Gilli
94190924bb doc: improve dns module's documentation
Make the difference between dns.lookup and other functions even clearer.

PR-URL: https://github.com/joyent/node/pull/8747
Signed-off-by: Timothy J Fontaine <tjfontaine@gmail.com>

Cherry-picked-from: 542234ad98
2015-01-10 22:28:50 +01:00
Julien Gilli
bfe04ed286 doc: clarify dns.lookup vs dns.resolve
Clarify and emphasize the differences between dns.lookup and the rest of
the functions in the dns module.

PR-URL: https://github.com/joyent/node/pull/8726
Reviewed-by: Chris Dickinson <christopher.s.dickinson@gmail.com>

Cherry-picked-from: 5ff59453a4
2015-01-10 22:28:48 +01:00
Julien Gilli
b91c535d86 doc: clarify url.format documentation
The original documentation was slightly confusing. It seemed that the
list of items described the properties of the urlObj object, while it
was actually describing the formatting process. This change makes this
clearer.

Reviewed-by: Chris Dickinson <christopher.s.dickinson@gmail.com>

Cherry-picked-from: 0603c8345b
2015-01-10 22:28:34 +01:00
James M Snell
3622f0308f doc: clarify buffer api documentation
Better wording for start and end parameters, also document .length
should be considered read-only.

PR-URL: https://github.com/joyent/node/pull/8910
Signed-off-by: Timothy J Fontaine <tjfontaine@gmail.com>

Cherry-picked-from: 102a861ec2
2015-01-10 22:28:32 +01:00
James M Snell
ff350f7169 doc: clarify add/removeListener semantics
Clarify that adding or removing a listener is not idempotent.

PR-URL: https://github.com/joyent/node/pull/8911
Signed-off-by: Timothy J Fontaine <tjfontaine@gmail.com>

Cherry-picked-from: 48536394c9
2015-01-10 22:28:16 +01:00
pkcs
f1e685fdfe doc: clearer log messages in net code samples
Code examples in documentation for net.createServer and
net.createConnection contained confusing log messages. This change makes
them clearer.

Signed-off-by: Julien Gilli <julien.gilli@joyent.com>

Cherry-picked-from: 8120015f40
2015-01-10 22:24:22 +01:00
Sam Roberts
c7b333b866 doc: cover stdio option in child_process
- Add hyperlinks from spawn options to subsections detailing what
those options do.
- Clarify some verbiage around ChildProcess.prototype.std{in,out,err}.
- Remove second-person pronoun.

PR-URL: https://github.com/joyent/node/pull/8639
Reviewed-by: Chris Dickinson <christopher.s.dickinson@gmail.com>

Cherry-picked-from: https://github.com/joyent/node/commit/3a08b7c3e0bc6757e70889196
2015-01-10 22:24:13 +01:00
Sam Roberts
37569cd2b2 doc: document the fds behind stdin/out/err
Its common knowledge on unix, but node documentation depends on knowing
this, as it exposes both streams named after stdio, and the fd numbers,
so make this explicit.

Fixes: https://github.com/joyent/node/pull/8624
PR-URL: https://github.com/joyent/node/pull/8454
Reviewed-by: Trevor Norris <trev.norris@gmail.com>

Cherry-picked-from: 13a992b1c2
2015-01-10 22:15:51 +01:00
Eric Mill
d8d1c4c87c doc: update openssl commands to use best practices
This updates key size to 2048 and default hash function to sha256.

Reviewed-by: Fedor Indutny <fedor@indutny.com>
PR-URL: https://github.com/joyent/node/pull/8690

Cherry-picked-from: 88bd95cfef
2015-01-10 22:15:49 +01:00
Calvin Metcalf
43226dd40e doc: add note about key derivation
adds a note to the crypto docs passing along
the advice that openssl gives about what
key derivation function they recommend.

PR-URL: https://github.com/joyent/node/pull/8580
Reviewed-by: Fedor Indutny <fedor@indutny.com>

Cherry-picked-from: 7dbc024c85
2015-01-10 22:15:48 +01:00
Calvin Metcalf
90f07a7b3e doc: document _transform callback takes 2 args
Expands the paragraph in the transform stream
implementation docs about the callback that is passed
to the _transform method to include details about how
two arguments may be passed, error and data.  A code
example is also included.

Reviewed-by: Fedor Indutny <fedor@indutny.com>

Cherry-picked-from: c8e0bdd7cf
2015-01-10 22:15:46 +01:00
Bert Belder
76ae73324e doc: add changelog notes for some node v0.10 releases 2015-01-10 22:15:45 +01:00
Ben Noordhuis
0526d834f9 Revert "dgram: implicit binds should be exclusive"
This reverts commit a32b92dbcf.

Reverted for breaking the parallel/test-cluster-dgram-2 test on all
platforms.

PR-URL: https://github.com/iojs/io.js/pull/279
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Rod Vagg <rod@vagg.org>
2015-01-10 16:34:18 +01:00
Sam Roberts
a32b92dbcf dgram: implicit binds should be exclusive
Server sockets should be shared by default, and client sockets should be
exclusive by default. For net/TCP, this is how it is, for dgram/UDP, its
a little less clear what a client socket is, but a socket that is
auto-bound during a dgram.send() is not usefully shared among cluster
workers, any more than an outgoing TCP connection would be usefully
shared.

Since implicit binds become exclusive, implicit/client dgram sockets can
now be used with cluster on Windows. Before, neither explicit nor
implicitly bound sockets could be used, causing dgram to be completely
unsupported with cluster on Windows. After this change, they become half
supported.

PR-URL: https://github.com/joyent/node/pull/8643
Reviewed-by: Bert Belder <bertbelder@gmail.com>
2015-01-10 04:50:50 +01:00
Sam Roberts
092c224e08 cluster: cluster.disconnect() should check status
Workers that are already disconnected but not yet exited should not be
disconnected, trying to do so raises exceptions.

PR-URL: https://github.com/joyent/node/pull/8642
Reviewed-by: Bert Belder <bertbelder@gmail.com>
2015-01-10 04:50:40 +01:00
Sam Roberts
14310e681e cluster: don't assume all workers bind same ports
For shared handles that do not get connection close messages (UDP/dgram
is the only example of this), cluster must not assume that a port
listened on by one worker is listened on by all workers.

PR-URL: https://github.com/joyent/node/pull/8642
Reviewed-by: Bert Belder <bertbelder@gmail.com>
2015-01-10 04:50:29 +01:00
Bert Belder
a80b9777f2 deps: don't build minizip into zlib
It's an optional extension that node/iojs doesn't use.

PR-URL: https://github.com/iojs/io.js/pull/276
Reviewed-by: Ben Noordhuis <info@bnoordhuis.nl>
2015-01-10 02:38:18 +01:00
Bert Belder
ad37509c0b deps: don't set zlib's product_name
PR-URL: https://github.com/iojs/io.js/pull/276
Reviewed-by: Ben Noordhuis <info@bnoordhuis.nl>
2015-01-10 02:38:18 +01:00
Ben Noordhuis
59ad4b0432 deps: fix zlib -Wimplicit-function-declaration
Build the bundled zlib with -DZ_HAVE_UNISTD_H to make the definition of
close(), read() and other unistd.h functions available to gzread.c and
gzwrite.c. It's kind of silly that we have to jump through hoops here
because we never call any of the functions that do I/O directly, but at
least it squelches the -Wimplicit-function-declaration warnings.

PR-URL: https://github.com/iojs/io.js/pull/273
Reviewed-by: Bert Belder <bertbelder@gmail.com>
2015-01-10 02:38:17 +01:00