platform/upstream/nodejs.git
12 years agodoc refactor: modules
isaacs [Mon, 27 Feb 2012 19:09:34 +0000 (11:09 -0800)]
doc refactor: modules

12 years agodoc refactor: https
isaacs [Mon, 27 Feb 2012 19:09:34 +0000 (11:09 -0800)]
doc refactor: https

12 years agodoc refactor: http
isaacs [Mon, 27 Feb 2012 19:09:33 +0000 (11:09 -0800)]
doc refactor: http

12 years agodoc refactor: globals
isaacs [Mon, 27 Feb 2012 19:09:33 +0000 (11:09 -0800)]
doc refactor: globals

12 years agodoc refactor: fs
isaacs [Mon, 27 Feb 2012 19:09:33 +0000 (11:09 -0800)]
doc refactor: fs

12 years agodoc refactor: events
isaacs [Mon, 27 Feb 2012 19:09:33 +0000 (11:09 -0800)]
doc refactor: events

12 years agodoc refactor: dns
isaacs [Mon, 27 Feb 2012 19:08:41 +0000 (11:08 -0800)]
doc refactor: dns

12 years agodoc refactor: dgram
isaacs [Mon, 27 Feb 2012 19:08:27 +0000 (11:08 -0800)]
doc refactor: dgram

12 years agodoc refactor: debugger
isaacs [Mon, 27 Feb 2012 19:08:17 +0000 (11:08 -0800)]
doc refactor: debugger

12 years agodoc refactor: crypto
isaacs [Mon, 27 Feb 2012 19:08:02 +0000 (11:08 -0800)]
doc refactor: crypto

12 years agodoc refactor: cluster
isaacs [Mon, 27 Feb 2012 19:07:49 +0000 (11:07 -0800)]
doc refactor: cluster

12 years agodoc refactor: buffers
isaacs [Mon, 27 Feb 2012 19:07:25 +0000 (11:07 -0800)]
doc refactor: buffers

12 years agodoc refactor: assert
isaacs [Mon, 27 Feb 2012 19:07:12 +0000 (11:07 -0800)]
doc refactor: assert

12 years agodoc refactor: appendix_1
isaacs [Mon, 27 Feb 2012 19:06:55 +0000 (11:06 -0800)]
doc refactor: appendix_1

12 years agodoc refactor: addons
isaacs [Mon, 27 Feb 2012 19:06:31 +0000 (11:06 -0800)]
doc refactor: addons

12 years agoAdd 'about these docs' section
isaacs [Mon, 27 Feb 2012 19:06:14 +0000 (11:06 -0800)]
Add 'about these docs' section

12 years agos/child_processes/child_process/
isaacs [Mon, 27 Feb 2012 19:04:08 +0000 (11:04 -0800)]
s/child_processes/child_process/

Conflicts:

doc/api/child_process.markdown

12 years agoRemove empty sections
isaacs [Mon, 27 Feb 2012 19:02:07 +0000 (11:02 -0800)]
Remove empty sections

12 years agoIncrease contrast of links, decrease contrast of bullets
isaacs [Mon, 27 Feb 2012 19:01:53 +0000 (11:01 -0800)]
Increase contrast of links, decrease contrast of bullets

12 years agoUpdate styles to reflect changed api doc html structure
isaacs [Mon, 27 Feb 2012 19:01:33 +0000 (11:01 -0800)]
Update styles to reflect changed api doc html structure

12 years agoUpdate template to use new token style
isaacs [Mon, 27 Feb 2012 18:59:51 +0000 (10:59 -0800)]
Update template to use new token style

Conflicts:

doc/template.html

12 years agoUse new doc generation tool
isaacs [Mon, 27 Feb 2012 18:59:35 +0000 (10:59 -0800)]
Use new doc generation tool

Conflicts:

Makefile

12 years agodocs: Move images out of the dist tarball
isaacs [Mon, 13 Feb 2012 22:47:50 +0000 (14:47 -0800)]
docs: Move images out of the dist tarball

This puts all images in doc/images/ and references them via
http://nodejs.org/images/.

Any complaints about copyright usage etc. can thus be node/joyent's
problem, rather than the problem of a downstream distribution channel.

Conflicts:

Makefile

12 years agoNew documentation generation tool
isaacs [Mon, 27 Feb 2012 18:59:01 +0000 (10:59 -0800)]
New documentation generation tool

12 years agochild_process: remove dummy "setsid" option setting
Joshua Holbrook [Sun, 26 Feb 2012 19:38:36 +0000 (11:38 -0800)]
child_process: remove dummy "setsid" option setting

12 years agonet: fix race write() before and after connect()
koichik [Sun, 26 Feb 2012 19:13:08 +0000 (04:13 +0900)]
net: fix race write() before and after connect()

Fixes #2827.

12 years agoRevert "docs: split TOC into two parts: overview and API"
isaacs [Mon, 27 Feb 2012 23:53:20 +0000 (15:53 -0800)]
Revert "docs: split TOC into two parts: overview and API"

This reverts commit cd4cb8e79509c3940a94bd70ff16cdb264884114.

12 years ago[ISSUE #2554 #2567] throw if fs args for 'start' or 'end' are strings
AJ ONeal [Sat, 18 Feb 2012 01:53:57 +0000 (18:53 -0700)]
[ISSUE #2554 #2567] throw if fs args for 'start' or 'end' are strings

12 years agopunycode: Update to v1.0.0
Mathias Bynens [Fri, 24 Feb 2012 15:05:10 +0000 (16:05 +0100)]
punycode: Update to v1.0.0

12 years agoupdate libuv to 9a5c1bad90
Igor Zinkovsky [Mon, 27 Feb 2012 21:16:06 +0000 (13:16 -0800)]
update libuv to 9a5c1bad90

12 years agoFix #2822 Only remove logo images, not logo html
isaacs [Mon, 27 Feb 2012 21:08:54 +0000 (13:08 -0800)]
Fix #2822 Only remove logo images, not logo html

12 years agodocs: split TOC into two parts: overview and API
tedsuo [Thu, 15 Dec 2011 00:44:59 +0000 (16:44 -0800)]
docs: split TOC into two parts: overview and API

Fixes #2090.
Fixes #2336.

12 years agoUpdate npm to 1.1.2
isaacs [Sat, 25 Feb 2012 02:52:17 +0000 (18:52 -0800)]
Update npm to 1.1.2

12 years agoMake a fat binary for the OS X pkg
isaacs [Wed, 22 Feb 2012 19:48:43 +0000 (11:48 -0800)]
Make a fat binary for the OS X pkg

12 years agoupdate libuv to c0e7044862
Igor Zinkovsky [Wed, 22 Feb 2012 20:04:39 +0000 (12:04 -0800)]
update libuv to c0e7044862

12 years agoPause process.stdin in stdin getter
isaacs [Tue, 21 Feb 2012 23:26:35 +0000 (15:26 -0800)]
Pause process.stdin in stdin getter

Otherwise, it'll be ref'ed, and keep the process hanging.

12 years agoAdd Håvard Stranden to AUTHORS file
isaacs [Tue, 21 Feb 2012 20:03:15 +0000 (12:03 -0800)]
Add Håvard Stranden to AUTHORS file

12 years agodocs: remove server.pause
Fedor Indutny [Tue, 21 Feb 2012 14:42:15 +0000 (20:42 +0600)]
docs: remove server.pause

This functionality was removed when libuv landed in node. It is useless
and can be easily implemented in user-land.

12 years agodocs: update man page
Ben Noordhuis [Sat, 18 Feb 2012 21:36:34 +0000 (22:36 +0100)]
docs: update man page

12 years agodocs: fix quotation style in the webserver example
Paul Vorbach [Sat, 18 Feb 2012 00:40:26 +0000 (01:40 +0100)]
docs: fix quotation style in the webserver example

Replace " by '

12 years agodocs: fix tls markdown
Ben Noordhuis [Fri, 17 Feb 2012 22:58:42 +0000 (23:58 +0100)]
docs: fix tls markdown

12 years agoMerge branch 'v0.6.11-release' into v0.6
isaacs [Fri, 17 Feb 2012 21:35:52 +0000 (13:35 -0800)]
Merge branch 'v0.6.11-release' into v0.6

12 years agoNow working on 0.6.12
isaacs [Fri, 17 Feb 2012 21:33:58 +0000 (13:33 -0800)]
Now working on 0.6.12

12 years ago2012.02.17 Version 0.6.11 (stable) v0.6.11
isaacs [Fri, 17 Feb 2012 00:04:34 +0000 (16:04 -0800)]
2012.02.17 Version 0.6.11 (stable)

* http: allow multiple WebSocket RFC6455 headers (Einar Otto Stangvik)

* http: allow multiple WWW-Authenticate headers (Ben Noordhuis)

* windows: support unicode argv and environment variables (Bert Belder)

* tls: mitigate session renegotiation attacks (Ben Noordhuis)

* tcp, pipe: don't assert on uv_accept() errors (Ben Noordhuis)

* tls: Allow establishing secure connection on the existing socket (koichik)

* dgram: handle close of dgram socket before DNS lookup completes (Seth Fitzsimmons)

* windows: Support half-duplex pipes (Igor Zinkovsky)

* build: disable omit-frame-pointer on solaris systems (Dave Pacheco)

* debugger: fix --debug-brk (Ben Noordhuis)

* net: fix large file downloads failing (koichik)

* fs: fix ReadStream failure to read from existing fd (Christopher Jeffrey)

* net: destroy socket on DNS error (Stefan Rusu)

* dtrace: add missing translator (Dave Pacheco)

* unix: don't flush tty on switch to raw mode (Ben Noordhuis)

* windows: reset brightness when reverting to default text color (Bert Belder)

* npm: update to 1.1.1
  - Update which, fstream, mkdirp, request, and rimraf
  - Fix #2123 Set path properly for lifecycle scripts on windows
  - Mark the root as seen, so we don't recurse into it. Fixes #1838. (Martin Cooper)

12 years agoRevert "cluster: propagate bind errors"
isaacs [Fri, 17 Feb 2012 18:10:02 +0000 (10:10 -0800)]
Revert "cluster: propagate bind errors"

This reverts commit 30e462e91937ced3847af3fe9c393ebd32294b68.

12 years agoFix #2770 Compile the OS X pkg as ia32
isaacs [Fri, 17 Feb 2012 18:08:40 +0000 (10:08 -0800)]
Fix #2770 Compile the OS X pkg as ia32

12 years agodocs: remove unused javascript includes
Shannen Saez [Thu, 16 Feb 2012 06:47:23 +0000 (17:47 +1100)]
docs: remove unused javascript includes

12 years agodocs: add lang="en" and remove redundant types
Shannen Saez [Thu, 16 Feb 2012 06:38:05 +0000 (17:38 +1100)]
docs: add lang="en" and remove redundant types

12 years agorepl: make tab completion work on non-objects
Nathan Rajlich [Fri, 17 Feb 2012 00:33:40 +0000 (16:33 -0800)]
repl: make tab completion work on non-objects

12 years agoUpgrade uv to 86ebe48660e
isaacs [Thu, 16 Feb 2012 22:52:03 +0000 (14:52 -0800)]
Upgrade uv to 86ebe48660e

12 years agocluster: propagate bind errors
Ben Noordhuis [Fri, 10 Feb 2012 19:26:56 +0000 (20:26 +0100)]
cluster: propagate bind errors

This commit fixes a bug where the cluster module failed to propagate EADDRINUSE
errors.

When a worker starts a (net, http) server, it requests the listen socket from
its master who then creates and binds the socket.

Now, OS X and Windows don't always signal EADDRINUSE from bind() but instead
defer the error until a later syscall. libuv mimics this behaviour to provide
consistent behaviour across platforms but that means the worker could end up
with a socket that is not actually bound to the requested addresss.

That's why the worker now checks if the socket is bound, raising EADDRINUSE if
that's not the case.

Fixes #2721.

12 years agoAdd WebSocket RFC6455 multiheader fields to the http parser.
einaros [Thu, 16 Feb 2012 09:42:13 +0000 (10:42 +0100)]
Add WebSocket RFC6455 multiheader fields to the http parser.

12 years agohttp: allow multiple WWW-Authenticate headers
Ben Noordhuis [Tue, 14 Feb 2012 23:20:54 +0000 (00:20 +0100)]
http: allow multiple WWW-Authenticate headers

12 years agoMake win32 ansi api usage explicit
Bert Belder [Thu, 16 Feb 2012 21:19:48 +0000 (22:19 +0100)]
Make win32 ansi api usage explicit

Use widechar versions in a couple of places.
Don't use C-style cast in C++ code.

12 years agoWindows: another attempt to support unicode argv
Bert Belder [Thu, 16 Feb 2012 19:20:07 +0000 (20:20 +0100)]
Windows: another attempt to support unicode argv

12 years agoRevert "Windows: support non-ansi command line arguments"
Bert Belder [Thu, 16 Feb 2012 19:05:18 +0000 (20:05 +0100)]
Revert "Windows: support non-ansi command line arguments"

CommandLineToArgvW doesn't behave exactly the same as the crt, which makes it useless.
This reverts commit ef032cbe85b46584304c665b539b4f7561c4c26c.

12 years agotls: mitigate session renegotiation attacks
Ben Noordhuis [Wed, 15 Feb 2012 18:26:43 +0000 (19:26 +0100)]
tls: mitigate session renegotiation attacks

The TLS protocol allows (and sometimes requires) clients to renegotiate the
session. However, renegotiation requires a disproportional amount of server-side
resources, particularly CPU time, which makes it a potential vector for
denial-of-service attacks.

To mitigate this issue, we keep track of and limit the number of renegotiation
requests over time, emitting an error if the threshold is exceeded.

12 years agodocs: removed unnecessary STARTTLS section
koichik [Thu, 16 Feb 2012 17:02:02 +0000 (02:02 +0900)]
docs: removed unnecessary STARTTLS section

12 years agoWindows: get rid of process._cwdForDrive()
Bert Belder [Wed, 15 Feb 2012 22:50:04 +0000 (23:50 +0100)]
Windows: get rid of process._cwdForDrive()

12 years agoWindows: use unicode environment
Bert Belder [Wed, 15 Feb 2012 22:34:18 +0000 (23:34 +0100)]
Windows: use unicode environment

12 years agotcp, pipe: don't assert on uv_accept() errors
Ben Noordhuis [Wed, 15 Feb 2012 15:45:02 +0000 (16:45 +0100)]
tcp, pipe: don't assert on uv_accept() errors

It's possible for a new connection to be closed in the window between the
accept() syscall and the call to uv_accept(). Deal with it and move on, don't
assert.

12 years agoadd tls-over-http-tunnel test
Igor Zinkovsky [Tue, 14 Feb 2012 08:03:13 +0000 (00:03 -0800)]
add tls-over-http-tunnel test

12 years agotls: Allow establishing secure connection on the existing socket
koichik [Mon, 9 Jan 2012 01:28:49 +0000 (02:28 +0100)]
tls: Allow establishing secure connection on the existing socket

12 years agodgram: handle close of dgram socket before DNS lookup completes
Seth Fitzsimmons [Tue, 14 Feb 2012 03:30:09 +0000 (19:30 -0800)]
dgram: handle close of dgram socket before DNS lookup completes

12 years agoWindows: support non-ansi command line arguments
Bert Belder [Mon, 13 Feb 2012 19:55:29 +0000 (20:55 +0100)]
Windows: support non-ansi command line arguments

12 years agoAdd libuv test that was omitted in last libuv upgrade
Bert Belder [Sun, 12 Feb 2012 20:07:31 +0000 (21:07 +0100)]
Add libuv test that was omitted in last libuv upgrade

12 years agoFix vcbuild.bat, print error when an unrecognized option is encountered
Bert Belder [Sun, 12 Feb 2012 20:04:03 +0000 (21:04 +0100)]
Fix vcbuild.bat, print error when an unrecognized option is encountered

12 years agotest: fix timing sensitivity in test-net-write-slow
koichik [Sat, 11 Feb 2012 17:05:30 +0000 (02:05 +0900)]
test: fix timing sensitivity in test-net-write-slow

12 years agodocs: update net.Server.address() documentation
Ben Noordhuis [Sat, 11 Feb 2012 13:24:15 +0000 (14:24 +0100)]
docs: update net.Server.address() documentation

12 years agoset readable/writable for pipes
Igor Zinkovsky [Fri, 10 Feb 2012 09:35:35 +0000 (01:35 -0800)]
set readable/writable for pipes

12 years agoupgrade uv to f9be43a564
Igor Zinkovsky [Fri, 10 Feb 2012 19:27:12 +0000 (11:27 -0800)]
upgrade uv to f9be43a564

12 years agodocs: clarify http 'data' callback
Ben Noordhuis [Fri, 10 Feb 2012 17:51:31 +0000 (18:51 +0100)]
docs: clarify http 'data' callback

Fixes #2733.

12 years agodocs: document tls/crypto `ciphers` option
Ben Noordhuis [Thu, 9 Feb 2012 16:14:39 +0000 (17:14 +0100)]
docs: document tls/crypto `ciphers` option

Hitherto undocumented option that lets the user select the list of ciphers to
use or exclude in a SSL/TLS session.

12 years agotest: add cluster 'bind twice' test
Ben Noordhuis [Thu, 9 Feb 2012 05:22:50 +0000 (06:22 +0100)]
test: add cluster 'bind twice' test

This test starts two clustered HTTP servers on the same port. It expects the
first cluster to succeed and the second cluster to fail with EADDRINUSE.

12 years agonpm: update to 1.1.1
isaacs [Wed, 8 Feb 2012 20:36:20 +0000 (12:36 -0800)]
npm: update to 1.1.1

12 years agodisable omit-frame-pointer on solaris systems
Dave Pacheco [Wed, 8 Feb 2012 00:50:05 +0000 (16:50 -0800)]
disable omit-frame-pointer on solaris systems

12 years agotest: add --debug-brk regression test
Ben Noordhuis [Tue, 7 Feb 2012 22:42:38 +0000 (23:42 +0100)]
test: add --debug-brk regression test

12 years agodebugger: fix --debug-brk
Ben Noordhuis [Tue, 7 Feb 2012 22:11:34 +0000 (23:11 +0100)]
debugger: fix --debug-brk

Commit 840229a forgot to update the debugger special case in lib/module.js

Fixes #2710.

12 years agoenable x64 windows build
Igor Zinkovsky [Tue, 7 Feb 2012 06:53:39 +0000 (22:53 -0800)]
enable x64 windows build
use "vcbuild x64" to do x64 build of node.exe

12 years agoRevert "Add explicit v8 locker"
Ben Noordhuis [Sun, 5 Feb 2012 22:30:14 +0000 (23:30 +0100)]
Revert "Add explicit v8 locker"

This reverts commit 11d1eca9f3c465045828e3a00b103620c8253258.

It sporadically (but reproducibly) triggers an assert inside V8:

  Fatal error in /path/to/node/deps/v8/src/isolate.cc, line 1857
  CHECK(CurrentPerIsolateThreadData()->isolate_ == this) failed

Needs further investigation.

12 years agodoc: add the note about 'data' event
koichik [Sun, 5 Feb 2012 10:11:54 +0000 (19:11 +0900)]
doc: add the note about 'data' event

Refs #2691.

12 years agonet: fix large file downloads failing
koichik [Fri, 3 Feb 2012 11:09:30 +0000 (20:09 +0900)]
net: fix large file downloads failing

Fixes #2678.

12 years agoAdd explicit v8 locker
Marcel Laverdet [Wed, 10 Aug 2011 21:39:03 +0000 (16:39 -0500)]
Add explicit v8 locker

v8 requires a lock of each thread using the vm, but if none is
explicitly is created it will implicitly create one for you. This
creates issues when trying to build modules which use v8's
multi-threading features because there's no lock to unlock.

12 years agofs: fix ReadStream fails to read from existing fd
Christopher Jeffrey [Thu, 2 Feb 2012 06:44:22 +0000 (00:44 -0600)]
fs: fix ReadStream fails to read from existing fd

A ReadStream constructed from an existing file descriptor failed to start
reading automatically. Avoids a userspace call to ReadStream.prototype._read().

12 years agotest: add tcp and https DNS error tests
Stefan Rusu [Fri, 3 Feb 2012 16:29:58 +0000 (18:29 +0200)]
test: add tcp and https DNS error tests

net-dns-error: specifc test for the net DNS issue.
http-dns-error: now it works for HTTPS as well.

12 years agonet: destroy socket on DNS error
Stefan Rusu [Fri, 3 Feb 2012 16:27:53 +0000 (18:27 +0200)]
net: destroy socket on DNS error

The socket was never destroyed on DNS errors. This broke some clients, including
lib/https.js.

12 years agoRename some occurrences of `process_1` back to `process`
Bert Belder [Fri, 3 Feb 2012 14:37:46 +0000 (15:37 +0100)]
Rename some occurrences of `process_1` back to `process`

12 years agodtrace: add missing translator
Dave Pacheco [Fri, 3 Feb 2012 01:02:09 +0000 (17:02 -0800)]
dtrace: add missing translator

Add missing translator for node_dtrace_http_*_request_t types.

Fixes #2667.

12 years agoNow working on v0.6.11
isaacs [Fri, 3 Feb 2012 01:19:28 +0000 (17:19 -0800)]
Now working on v0.6.11

12 years ago2012.02.02, Version 0.6.10 (stable) v0.6.10
isaacs [Fri, 3 Feb 2012 00:04:47 +0000 (16:04 -0800)]
2012.02.02, Version 0.6.10 (stable)

* Update V8 to 3.6.6.20

* Add npm msysgit bash shim to msi installer (isaacs)

* buffers: fix intermittent out of bounds error (Ben Noordhuis)

* buffers: honor length argument in base64 decoder (Ben Noordhuis)

* windows: Fix path.exists regression (Bert Belder)

* Make QueryString.parse run faster (Philip Tellis)

* http: avoid freeing http-parser objects too early (koichik)

* timers: add v0.4 compatibility hack (Ben Noordhuis)

* Proper EPERM error code support (Igor Zinkovsky, Brandon Philips)

* dgram: Implement udp multicast methods on windows (Bert Belder)

12 years agomsi: npm bash shim fixes
isaacs [Fri, 3 Feb 2012 00:56:23 +0000 (16:56 -0800)]
msi: npm bash shim fixes

12 years agoPatches floating on v8
isaacs [Thu, 2 Feb 2012 23:37:59 +0000 (15:37 -0800)]
Patches floating on v8

12 years agoUpgrade v8 to 3.6.6.20
isaacs [Thu, 2 Feb 2012 23:35:14 +0000 (15:35 -0800)]
Upgrade v8 to 3.6.6.20

12 years agoAdd npm msysgit bash shim to msi installer
isaacs [Thu, 2 Feb 2012 22:57:12 +0000 (14:57 -0800)]
Add npm msysgit bash shim to msi installer

12 years agobuffers: fix intermittent out of bounds error
Ben Noordhuis [Wed, 1 Feb 2012 21:37:26 +0000 (22:37 +0100)]
buffers: fix intermittent out of bounds error

The base64 decoder would intermittently throw an out-of-bounds exception when
the buffer in `buf.write('', 'base64')` was a zero-sized buffer located at the
end of the slab.

Fixes #2657.

12 years agobuffers: honor length argument in base64 decoder
Ben Noordhuis [Wed, 1 Feb 2012 21:07:42 +0000 (22:07 +0100)]
buffers: honor length argument in base64 decoder

Honor the length argument in `buf.write(s, 0, buf.length, 'base64')`. Before
this commit, the length argument was ignored. The decoder would keep writing
until it hit the end of the buffer. Since most buffers in Node are slices of
a parent buffer (the slab), this bug would overwrite the content of adjacent
buffers.

The bug is trivially demonstrated with the following test case:

    var assert = require('assert');
    var a = Buffer(3);
    var b = Buffer('xxx');
    a.write('aaaaaaaa', 'base64');
    assert.equal(b.toString(), 'xxx');

This commit coincidentally also fixes a bug where Buffer._charsWritten was not
updated for zero length buffers.

12 years agouv: upgrade to 267e75d
Bert Belder [Thu, 2 Feb 2012 16:42:08 +0000 (17:42 +0100)]
uv: upgrade to 267e75d

12 years ago_makeLong shouldn't turn the empty string into \\?\C:\
Bert Belder [Thu, 2 Feb 2012 15:57:45 +0000 (16:57 +0100)]
_makeLong shouldn't turn the empty string into \\?\C:\

12 years agoRun path.exists paths through _makeLong
Bert Belder [Thu, 2 Feb 2012 15:56:58 +0000 (16:56 +0100)]
Run path.exists paths through _makeLong

12 years agoMake QueryString.parse run faster
Philip Tellis [Fri, 2 Dec 2011 18:42:32 +0000 (00:12 +0530)]
Make QueryString.parse run faster

Use decodeURIComponent when appropriate, and only fall back to
querystring.decode if it throws, or if the character is a '+'.

Fix #2248