Commit Graph

8776 Commits (7989f42f866699b726f596add387fb19fa39bc55)

Author SHA1 Message Date
Ben Noordhuis 7989f42f86 build: fix g++ 4.8 build, disable -Werror
Turn off -Werror when building V8, it hits -Werror=unused-local-typedefs
with g++ 4.8.  The warning itself is harmless so don't abort the build.

This was originally implemented in commit d2ab314e back in 2011 but the
build process has gone through a few iterations since then, that change
no longer works.
2014-03-23 16:11:08 -07:00
Shuhei Kagawa 43a29f53ca doc: remove an unused arg in process.stdin.
The argument of process.stdin's readable event handler is not used.
2014-03-10 15:30:40 -07:00
Fedor Indutny f0d870501e crypto: do not lowercase cipher/hash names
`crypto.getCiphers()` and `crypto.getHashes()` should prefer lower-case
variants of names, but should not introduce them.

fix #7282
2014-03-11 01:08:43 +04:00
Ben Noordhuis 6bd78fd770 deps: fix v8 valgrind warning
Fix the following valgrind warning:

    Conditional jump or move depends on uninitialised value(s)
        at 0x7D64E7: v8::internal::GlobalHandles::IterateAllRootsWithClassIds(v8::internal::ObjectVisitor*) (global-handles.cc:613)
        by 0x94DCDC: v8::internal::NativeObjectsExplorer::FillRetainedObjects() (profile-generator.cc:2849)
        # etc.

This was fixed upstream in r12903 and released in 3.15.2 but that commit
was never back-ported to the 3.14 branch that node.js v0.10 uses.

The code itself works okay; this commit simply shuffles the clauses in
an `if` statement to check that the node is in use before checking its
class id (which is uninitialized if the node is not in use.)
2014-03-07 03:29:00 +04:00
Fedor Indutny 5e06ce4fb9 child_process: fix sending handle twice
When sending a socket to a child process via IPC pipe,
`child_process.js` picks a raw UV handle from `_handle` property, sends
it, and assigns `null` to the property. Sending the same socket twice
was resulting in a runtime error, since we weren't handling the empty
`_handle` case.

In case of `null` `_handle` we should send just a plain text message
as passed it was passed to `.send()` and ignore the handle, letting
users handle such cases themselves instead of throwing the error at
runtime.

fix #5469
2014-03-05 09:36:35 -08:00
Benoit Vallée a9d24fa40d test: test sending a handle twice
Added test-cluster-send-handle-twice.js testing to send a handle
twice to the parent process.
2014-03-05 09:36:32 -08:00
Ben Noordhuis bd8a5755dc src: add default visibility to NODE_MODULE
It's currently not really possible to compile native add-ons with
-fvisibility=hidden because that also hides the struct containing
the module definition.

The NODE_MODULE() and NODE_MODULE_DECL() macros are structured in
a way that makes it impossible to add a visibility attribute manually
so there is no escape hatch there.

That's why this commit adds an explicit visibility attribute to
the module definition.  It doesn't help with node.js releases that
are already out there but at least it improves the situation going
forward.
2014-03-05 15:26:09 +04:00
Greg Brail 6eb4d1d15c timer: don't reschedule timer bucket in a domain
If two timers run on the same tick, and the first timer uses a domain,
and then catches an exception and disposes of the domain, then the
second timer never runs. (And even if the first timer does not dispose
of the domain, the second timer could run under the wrong domain.)

This happens because timer.js uses "process.nextTick()" to schedule
continued processing of the timers for that tick. However, there was
an exception inside a domain, then "process.nextTick()" runs under
the domain of the first timer function, and will do nothing if
the domain has been disposed.

To avoid this, we temporarily save the value of "process.domain"
before calling nextTick so that it does not run inside any domain.
2014-03-03 17:46:49 -08:00
Timothy J Fontaine 06453a94a7 src: domain should not replace nextTick function
Previously if you cached process.nextTick and then require('domain')
subsequent nextTick() calls would not be caught because enqueued
functions were taking the wrong path. This keeps nextTick to a single
function reference and changes the implementation details after domain
has been required.
2014-03-03 16:27:58 -08:00
Nathan Rajlich 47abdd9c43 test: add `agent: null` http client request test
This is just the test portion from #7012 / #7189,
but targetted for the v0.10 branch.
2014-02-26 11:39:53 -08:00
Nathan Rajlich 0a01a42e87 http: invoke createConnection when no agent
This makes it so that the user may pass in a
`createConnection()` option, and they don't have
to pass `agent: false` at the same time.

Also adding a test for the `createConnection` option,
since none was in place before.

See #7014.
2014-02-26 11:14:32 -08:00
Mike Pennisi aae51ecf7d assert: Ensure reflexivity of deepEqual
Ensure that the behavior of `assert.deepEqual` does not depend on
argument ordering  when comparing an `arguments` object with a
non-`arguments` object.
2014-02-25 20:32:49 +04:00
Brian White 70ea5bac43 stream: remove useless check 2014-02-24 15:08:11 +04:00
Nicolas Talle 1efe6837b2 doc: update assert.markdown
Update assert.throws() and assert.doesNotThrow() docs
2014-02-23 18:09:26 +04:00
Fedor Indutny e0c5302590 installer: copy `node.d` only with node_use_dtrace 2014-02-21 01:03:03 +04:00
Fedor Indutny a6f89ccd76 dtrace: workaround linker bug on FreeBSD 2014-02-21 00:56:17 +04:00
Fedor Indutny b7776fb192 configure: allow --with-dtrace on freebsd 2014-02-21 00:46:26 +04:00
Fedor Indutny b940e0fd86 gyp: specialize node.d for freebsd
`node.d` should use `psinfo.d` instead of `procfs.d` and have statically
defined architecture on FreeBSD.
2014-02-21 00:46:26 +04:00
Timothy J Fontaine 085db9dd6c tools: update to support separate website repo 2014-02-18 18:57:45 -08:00
Timothy J Fontaine ae418f974d Now working on v0.10.27 2014-02-18 16:43:12 -08:00
Timothy J Fontaine 0206925b0d Merge branch 'v0.10.26-release' into v0.10 2014-02-18 16:40:23 -08:00
Timothy J Fontaine cc56c62ed8 build: readd missing installer resources
This were accidentally moved during the website refactor
2014-02-18 15:34:29 -08:00
Timothy J Fontaine 31c510ca88 2014.02.18, Version 0.10.26 (Stable)
* uv: Upgrade to v0.10.25 (Timothy J Fontaine)

* npm: upgrade to 1.4.3 (isaacs)

* v8: support compiling with VS2013 (Fedor Indutny)

* cares: backport TXT parsing fix (Fedor Indutny)

* crypto: throw on SignFinal failure (Fedor Indutny)

* crypto: update root certificates (Ben Noordhuis)

* debugger: Fix breakpoint not showing after restart (Farid Neshat)

* fs: make unwatchFile() insensitive to path (iamdoron)

* net: do not re-emit stream errors (Fedor Indutny)

* net: make Socket destroy() re-entrance safe (Jun Ma)

* net: reset `endEmitted` on reconnect (Fedor Indutny)

* node: do not close stdio implicitly (Fedor Indutny)

* zlib: avoid assertion in close (Fedor Indutny)
2014-02-18 14:55:58 -08:00
Anton Khlynovskiy 1fa5cff4f2 docs: clarify process.stdin and old mode 2014-02-18 13:52:14 -08:00
Pedro Ballesteros 1d734a75b5 doc: stdout blocking or non-blocking behaviour
Makes clear that the behaviour of stdout is blocking
in Linux/Unix even when they refer to pipes.
2014-02-18 13:36:00 -08:00
Timothy J Fontaine 3e6e63406d test: make test-net-error-twice less racey 2014-02-18 13:10:09 -08:00
Timothy J Fontaine c2aea3747d uv: Upgrade to v0.10.25 2014-02-18 13:04:29 -08:00
Raynos abbde2fafa doc: mention objectMode for Writable streams 2014-02-18 10:29:04 -08:00
Farid Neshat 562b015170 debugger: Fix breakpoint not showing after restart
The reason this wasn't working was because after restart, when restoring
breakpoints the scripts wasn't loaded, so the breakpoint.script was
undefined. As a fix I added another check to use breakpoint.scriptReq
instead of breakpoint.script, which is the same except when the
breakpoint is a function.

fixes #7027
2014-02-17 20:47:46 -08:00
isaacs 217bb0c964 npm: upgrade to 1.4.3 2014-02-17 19:37:33 -08:00
Fedor Indutny 829a9b8cba zlib: introduce pending close state
zlib should not crash in `close()` if the write is still in progress.

fix #7101
2014-02-18 01:11:05 +04:00
Timothy J Fontaine 86b8d84811 doc: re-add node.1 man page
The man page was accidentally removed in 37376de for the website
refactor, bring it back.

Fixes #7117
2014-02-14 11:01:49 -08:00
isaacs 55543d3c45 npm: Upgrade to v1.4.0
- Removes 'npm publish -f'
- Documentation
- Bug-fixes
- Update license etc to refer to npm, Inc. rather than @isaacs personally
2014-02-13 16:35:41 -08:00
Timothy J Fontaine 37376debe5 website: move website to joyent/node-website
The website will no longer be living in the source repository instead
it can be found at http://github.com/joyent/node-website
2014-02-13 15:54:07 -08:00
Christian b222374b07 doc: changed timer id to object
fix #7074
2014-02-13 02:18:10 +04:00
Fedor Indutny dee5270a6c net: do not re-emit stream errors
fix #7015
2014-02-10 10:59:52 -08:00
Timothy J Fontaine 5c832e44c3 src: refactor buffer bounds checking
Consolidate buffer bounds checking logic into Buffer namespace and use
it consistently throughout the source.
2014-02-08 15:31:27 -08:00
isaacs 2e8bb57fe3 npm: upgrade to 1.3.26 2014-02-08 15:10:43 -08:00
Brian White 3595139b51 doc: fix diffieHellman.getGenerator() description 2014-02-09 02:42:41 +04:00
Fedor Indutny d10a68736d Revert "dns: validate arguments in resolve"
This reverts commit 56e80a37e0.
2014-02-08 02:15:33 +04:00
Fedor Indutny 96379f83e0 Revert "dns: verify argument is valid function in resolve"
This reverts commit 2ee86c624e.
2014-02-08 02:15:29 +04:00
Kenan Sulayman 2ee86c624e dns: verify argument is valid function in resolve
Don't use argument as callback if it's not a valid callback function.
Throw a valid exception instead explaining the issue. Adds to #7070
("DNS — Throw meaningful error(s)").
2014-02-08 02:10:01 +04:00
Kenan Sulayman 56e80a37e0 dns: validate arguments in resolve
Mitigat  C++-land assertion error, add test accordingly.

fix #7070
2014-02-08 02:08:28 +04:00
Timothy J Fontaine e3d8359021 website: update cla email address 2014-02-07 11:17:23 -08:00
iamdoron 1317032c97 fs: make unwatchFile() insensitive to path 2014-02-06 13:04:35 +04:00
Benjamin Waters d2147c55c2 doc: fix references to error keyword
References for err.signal and err.code should be error.signal and
error.code.

Fixes joyent/node#6862
2014-02-04 12:50:24 +04:00
Ben Noordhuis 09c51d5e40 crypto: update root certificates
Update the list of root certificates in src/node_root_certs.h with
tools/mk-ca-bundle.pl and update src/node_crypto.cc to make use of
the new format.

Fixes #6013.
2014-02-04 01:42:52 +04:00
Maxime Quandalle 154d9d2163 doc: add an example about multiple extensions
`path.extname` returns only the last extension
2014-02-03 12:38:40 +04:00
Fedor Indutny 643a7d8c16 dtrace: fix arguments warning
Add enough arguments to `NODE_NET_SOCKET_READ()` and
`NODE_NET_SOCKET_WRITE()` stubs.
2014-02-01 00:45:55 +04:00
Fedor Indutny fac8f396cc deps: backport 883637bd from latest v8
Original commit message:

  VS2013 contains a number of improvements, most notably the addition
  of all C99 math functions.

  I'm a little bit concerned about the change I had to make in
  cpu-profiler.cc, but I spent quite a bit of time looking at it and was
  unable to figure out any rational explanation for the warning. It's
  possible it's spurious. Since it seems like a useful warning in
  general   though, I chose not to disable globally at the gyp level.

  I do think someone with expertise here should probably try to
  determine if this is a legitimate warning.

  BUG=288948
  R=dslomov@chromium.org

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

NOTE: Path applied without `cpu-profiler.cc` changes because in our
version it was looking totally different.
2014-02-01 00:45:55 +04:00