platform/upstream/nodejs.git
12 years agoNow working on v0.5.11
Ryan Dahl [Sat, 22 Oct 2011 02:16:06 +0000 (19:16 -0700)]
Now working on v0.5.11

12 years agoBump version to v0.5.10 v0.5.10
Ryan Dahl [Sat, 22 Oct 2011 00:02:11 +0000 (17:02 -0700)]
Bump version to v0.5.10

12 years agouv: upgrade to 179f475
Ben Noordhuis [Sat, 22 Oct 2011 01:44:06 +0000 (18:44 -0700)]
uv: upgrade to 179f475

12 years agonet: bring back .setNoDelay() and .setKeepAlive()
Ben Noordhuis [Sat, 22 Oct 2011 00:07:11 +0000 (17:07 -0700)]
net: bring back .setNoDelay() and .setKeepAlive()

12 years agouv: upgrade to ec825ff
Ben Noordhuis [Sat, 22 Oct 2011 00:08:12 +0000 (17:08 -0700)]
uv: upgrade to ec825ff

12 years agoMerge remote branch 'origin/v0.4'
Ryan Dahl [Sat, 22 Oct 2011 00:58:04 +0000 (17:58 -0700)]
Merge remote branch 'origin/v0.4'

Conflicts:
ChangeLog
Makefile
deps/libev/wscript
doc/index.html
doc/template.html
lib/net.js
src/node_version.h
src/platform_cygwin.cc
test/pummel/test-net-write-callbacks.js
test/simple/test-buffer.js

12 years agomake simple\test-fs-symlink.js work on windows
Igor Zinkovsky [Sat, 22 Oct 2011 00:08:50 +0000 (17:08 -0700)]
make simple\test-fs-symlink.js work on windows

12 years agotest: #1899 - output in child process raises an exception
Maciej Małecki [Fri, 21 Oct 2011 22:32:12 +0000 (00:32 +0200)]
test: #1899 - output in child process raises an exception

12 years agogetaddrinfo returns ENOTFOUND for invalid domain names
Ryan Dahl [Fri, 21 Oct 2011 22:19:49 +0000 (15:19 -0700)]
getaddrinfo returns ENOTFOUND for invalid domain names

change test-http-dns-error to reflect this.

12 years agoFix test-eio-race on Windows
Ryan Dahl [Fri, 21 Oct 2011 21:54:11 +0000 (14:54 -0700)]
Fix test-eio-race on Windows

12 years agogyp: upgrade to r1081
Ben Noordhuis [Fri, 21 Oct 2011 20:43:49 +0000 (13:43 -0700)]
gyp: upgrade to r1081

12 years agoUpgrade libuv to 7738306
Ryan Dahl [Fri, 21 Oct 2011 20:44:30 +0000 (13:44 -0700)]
Upgrade libuv to 7738306

12 years agoEmit 'end' from crypto streams on close
Ryan Dahl [Fri, 21 Oct 2011 20:07:48 +0000 (13:07 -0700)]
Emit 'end' from crypto streams on close

Fixes test/simple/test-tls-peer-certificate.js on Windows

Patch from bnoordhuis.

See also 75a0cf970fb48440a93a62796ab1f128fcbe7d76

12 years agoAdd useGlobal flag for standard node repl
isaacs [Thu, 20 Oct 2011 17:00:15 +0000 (10:00 -0700)]
Add useGlobal flag for standard node repl

12 years agoRevert "Don't use a separate context for the repl."
isaacs [Thu, 20 Oct 2011 15:54:50 +0000 (08:54 -0700)]
Revert "Don't use a separate context for the repl."

This reverts commit b70fed48a7fb0ac884e6574253a89db6158b2f60.

12 years agobuild: fix wscript on solaris
Ben Noordhuis [Fri, 21 Oct 2011 19:46:52 +0000 (12:46 -0700)]
build: fix wscript on solaris

os.path.exists() in python 2.5.2 returns false for symlinks.

12 years agomake process.kill a no-op on windows
Igor Zinkovsky [Fri, 21 Oct 2011 16:08:19 +0000 (09:08 -0700)]
make process.kill a no-op on windows

12 years agoFix race condition in test-dgram-pingpong
Ryan Dahl [Fri, 21 Oct 2011 17:21:23 +0000 (10:21 -0700)]
Fix race condition in test-dgram-pingpong

12 years agohttp: improve http parser bindings
Ben Noordhuis [Tue, 27 Sep 2011 15:07:56 +0000 (17:07 +0200)]
http: improve http parser bindings

Speeds up HTTP benchmarks by 10% on average.

12 years agodns.lookup uses cares_wrap::GetAddrInfo
Ryan Dahl [Fri, 21 Oct 2011 00:52:50 +0000 (17:52 -0700)]
dns.lookup uses cares_wrap::GetAddrInfo

12 years agoUpgrade libuv to 2c7e8bb
Ryan Dahl [Fri, 21 Oct 2011 00:52:32 +0000 (17:52 -0700)]
Upgrade libuv to 2c7e8bb

12 years agoFix windows build
Bert Belder [Thu, 20 Oct 2011 22:40:08 +0000 (15:40 -0700)]
Fix windows build

12 years agouv: upgrade to 28234d7
Ben Noordhuis [Thu, 20 Oct 2011 22:25:57 +0000 (15:25 -0700)]
uv: upgrade to 28234d7

12 years agoAdd binding to uv_getaddrinfo
Ryan Dahl [Thu, 20 Oct 2011 22:06:53 +0000 (15:06 -0700)]
Add binding to uv_getaddrinfo

12 years agorepl: print out `undefined`
Nathan Rajlich [Wed, 19 Oct 2011 20:46:06 +0000 (13:46 -0700)]
repl: print out `undefined`

util.inspect() has a special case for "undefined", so it's nice to be able to
distinguish visually that undefined is the result of an expression.

12 years agodebugger: fix backtrace err handling
Fedor Indutny [Thu, 20 Oct 2011 05:07:20 +0000 (09:07 +0400)]
debugger: fix backtrace err handling

12 years agodocs: improve buffer.fill() documentation
Ben Noordhuis [Thu, 20 Oct 2011 01:20:42 +0000 (18:20 -0700)]
docs: improve buffer.fill() documentation

Fixes #1912.

12 years agoDisplay sys_errno when UV_UNKNOWN is returned
Ryan Dahl [Wed, 19 Oct 2011 23:53:07 +0000 (16:53 -0700)]
Display sys_errno when UV_UNKNOWN is returned

12 years agoRemove os.openOSHandle
Ryan Dahl [Wed, 19 Oct 2011 23:28:52 +0000 (16:28 -0700)]
Remove os.openOSHandle

Unused.

12 years agoRemove support for cygwin
Ryan Dahl [Wed, 19 Oct 2011 23:23:26 +0000 (16:23 -0700)]
Remove support for cygwin

12 years agoRevert "Fix #1801 vm: Use 'sandbox' as global_prototype"
Ryan Dahl [Wed, 19 Oct 2011 18:01:08 +0000 (11:01 -0700)]
Revert "Fix #1801 vm: Use 'sandbox' as global_prototype"

Accidentally committed. Revert until review.

This reverts commit 200df8641b43902adc73cce6b89d3e84a91dd3e6.

12 years agohttp: Added support for HTTP PATCH verb
Thomas Parslow [Tue, 18 Oct 2011 13:15:58 +0000 (14:15 +0100)]
http: Added support for HTTP PATCH verb

Fixes #1907.

12 years agobuffer: use NO_NULL_TERMINATION flag
koichik [Mon, 17 Oct 2011 13:13:18 +0000 (22:13 +0900)]
buffer: use NO_NULL_TERMINATION flag

Refs #394.
Fixes #1902.

12 years agoDon't use a separate context for the repl.
isaacs [Tue, 18 Oct 2011 01:24:12 +0000 (18:24 -0700)]
Don't use a separate context for the repl.

Fix #1484
Fix #1834
Fix #1482
Fix #771

It's been a while now, and we've seen how this separate context thing
works.  It constantly confuses people, and no one actually uses '.clear'
anyway, so the benefit of that feature does not justify the constant
WTFery.

This makes repl.context actually be a getter that returns the global
object, and prints a deprecation warning.  The '.clear' command is gone,
and will report that it's an invalid repl keyword.  Tests updated to
allow the require, module, and exports globals, which are still
available in the repl just like they were before, by making them global.

12 years agoFix #1801 vm: Use 'sandbox' as global_prototype
elliottcable [Fri, 14 Oct 2011 07:42:18 +0000 (03:42 -0400)]
Fix #1801 vm: Use 'sandbox' as global_prototype

Squashed commit:

(- re tests) Cleaning up the `Script` test suite.

For whatever reason, there were several duplicate test files related to `Script`
and the `'vm'` module. I removed these, and fixed a few other small issues.
(More fixes coming in subsequent commits.)

Squashes: 19e86045a0..1e3dcff4eb

(api fix:1801 new:1801) `'vm'` module uses sandbox as prototype

As described in GH-1801, the `'vm'` module was handling the `sandbox` object
provided by the API consumer in a particularly terrible and fragile fashion: it
was simply shallow-copying any enumerable properties from the sandbox onto the
global context before executing the code, and then eventually copying any values
on the global context back into the sandbox object *afterwards*.

This commit removes all of that implementation, and utilizes the passed sandbox
object as the *prototype of the context* instead. A bit of a hack, but a very
effective one.

This no longer allows for new variables created in the global context to be
placed into your sandbox after execution has completed, but that’s for the best
anyway, as it’s not very in line with the concept of a “box of passed-in
context.” I’m planning to further implement an interface for API consumers to
acquire the *actual global* from within the VM soon, thus allowing for
separation-of-concerns: providing data *to* the VM via the sandbox-prototype,
and exploring the internal environment of the VM itself.

// GitHub cruft: closes #1801

Squashes: 43b8e3c..209ed86

12 years agoFix test-c-ares.js on Windows by disabling PTR test
Ryan Dahl [Tue, 18 Oct 2011 23:12:07 +0000 (16:12 -0700)]
Fix test-c-ares.js on Windows by disabling PTR test

12 years agoRemove superfluous nextTick during server binding
Ryan Dahl [Tue, 18 Oct 2011 22:12:16 +0000 (15:12 -0700)]
Remove superfluous nextTick during server binding

This breaks fork().send({}, server._handle) after server.listen() because
server._handle is not set.

12 years agoUpgrade GYP to r1078
Ryan Dahl [Tue, 18 Oct 2011 21:38:48 +0000 (14:38 -0700)]
Upgrade GYP to r1078

12 years agoRemove process.memoryUsage().vsize
Ryan Dahl [Tue, 18 Oct 2011 21:30:31 +0000 (14:30 -0700)]
Remove process.memoryUsage().vsize

Not meaningful cross platform; unused.

12 years agoFixes #1860. Remove process.writeError
Ryan Dahl [Tue, 11 Oct 2011 23:06:40 +0000 (16:06 -0700)]
Fixes #1860. Remove process.writeError

Breaks a few tests in "make test-message"

12 years agohttp: add test for #1885
koichik [Sun, 16 Oct 2011 15:32:13 +0000 (00:32 +0900)]
http: add test for #1885

12 years agohttp: tiny fix in http.js
Yoshihiro Kikuchi [Thu, 13 Oct 2011 08:48:30 +0000 (17:48 +0900)]
http: tiny fix in http.js

Fixes #1885.

12 years agodocs: improvement tls example
koichik [Sun, 16 Oct 2011 07:31:41 +0000 (16:31 +0900)]
docs: improvement tls example

12 years agotest: fix test-child-process-stdin and test-child-process-kill on windows
Igor Zinkovsky [Sat, 15 Oct 2011 19:21:15 +0000 (12:21 -0700)]
test: fix test-child-process-stdin and test-child-process-kill on windows

12 years agonet: fix error handling in listen()
koichik [Sat, 15 Oct 2011 08:10:14 +0000 (17:10 +0900)]
net: fix error handling in listen()

Fixes #1894.

12 years agodocs: add example of tls
koichik [Sat, 15 Oct 2011 16:26:38 +0000 (01:26 +0900)]
docs: add example of tls

12 years agotls: The TLS API is inconsistent with the TCP API
koichik [Sat, 15 Oct 2011 10:27:21 +0000 (19:27 +0900)]
tls: The TLS API is inconsistent with the TCP API

Add 'secureConnect' event to tls.CleartextStream.

Fixes #1467.

12 years agonet: fix connect queue bugs
Ben Noordhuis [Sat, 15 Oct 2011 01:27:25 +0000 (03:27 +0200)]
net: fix connect queue bugs

This commit fixes two bugs in the handling of write requests when the connect()
call is still in progress.

1. The deferred write request's size was counted twice towards `.bytesWritten`.

2. The callback was not called. After connecting, `Socket.write()` was called
   with three arguments (data, encoding, cb) but it ignored the third argument.

Coincidentally fixes test/simple/test-net-connect-buffer.js.

12 years agonet: properly account multi-byte chars in .bytesWritten
Ben Noordhuis [Sat, 15 Oct 2011 01:10:53 +0000 (03:10 +0200)]
net: properly account multi-byte chars in .bytesWritten

12 years agowin: remove pthread-win32 init code
Igor Zinkovsky [Sat, 15 Oct 2011 00:47:01 +0000 (17:47 -0700)]
win: remove pthread-win32 init code

12 years agobuild: fix windows build
Igor Zinkovsky [Fri, 14 Oct 2011 23:58:18 +0000 (16:58 -0700)]
build: fix windows build

12 years agotest: fix bug in setproctitle test
Ben Noordhuis [Sat, 15 Oct 2011 00:05:33 +0000 (02:05 +0200)]
test: fix bug in setproctitle test

Output from `ps` may contain trailing whitespace, trim it.

12 years agov8: implement VirtualMemory class on SunOS
Ben Noordhuis [Mon, 10 Oct 2011 22:32:54 +0000 (22:32 +0000)]
v8: implement VirtualMemory class on SunOS

Unbreaks build on SunOS. Un-reverts 9bbca99107652906a060679ee95bf1ad7381cbb5.

12 years agodoc: Add examples of zlib usage with http
isaacs [Fri, 14 Oct 2011 16:20:05 +0000 (09:20 -0700)]
doc: Add examples of zlib usage with http

12 years agotest: check that EventEmitter.on == EventEmitter.addListener
Ben Noordhuis [Fri, 14 Oct 2011 23:01:57 +0000 (01:01 +0200)]
test: check that EventEmitter.on == EventEmitter.addListener

12 years agotest: replace .addListener() calls with .on()
Ben Noordhuis [Fri, 14 Oct 2011 23:08:36 +0000 (01:08 +0200)]
test: replace .addListener() calls with .on()

12 years agouv: upgrade to 456f831
Ben Noordhuis [Fri, 14 Oct 2011 22:42:10 +0000 (00:42 +0200)]
uv: upgrade to 456f831

12 years agotls: requestCert unusable with Firefox and Chrome
koichik [Wed, 21 Sep 2011 04:19:22 +0000 (13:19 +0900)]
tls: requestCert unusable with Firefox and Chrome

Fixes #1516.

12 years agochild_process.fork: don't modify args
koichik [Fri, 14 Oct 2011 08:04:04 +0000 (17:04 +0900)]
child_process.fork: don't modify args

Fixes #1888.

12 years agonode: fix use of potentially uninitialized variable
Ben Noordhuis [Fri, 14 Oct 2011 15:05:02 +0000 (15:05 +0000)]
node: fix use of potentially uninitialized variable

12 years agotimer_wrap: add sanity check assert
Ben Noordhuis [Fri, 14 Oct 2011 15:00:37 +0000 (15:00 +0000)]
timer_wrap: add sanity check assert

12 years agotcp_wrap: add sanity check asserts
Ben Noordhuis [Fri, 14 Oct 2011 14:58:41 +0000 (14:58 +0000)]
tcp_wrap: add sanity check asserts

12 years agonode_script: remove unused variable
Ben Noordhuis [Fri, 14 Oct 2011 14:50:38 +0000 (14:50 +0000)]
node_script: remove unused variable

12 years agonode: fix arguments to uv_timer_start()
Ben Noordhuis [Fri, 14 Oct 2011 14:43:49 +0000 (14:43 +0000)]
node: fix arguments to uv_timer_start()

12 years agocares_wrap: make destructor virtual
Ben Noordhuis [Fri, 14 Oct 2011 14:39:21 +0000 (14:39 +0000)]
cares_wrap: make destructor virtual

A class with virtual methods should have a virtual destructor.

12 years agoUpgrade V8 to 3.7.0
Ryan Dahl [Fri, 14 Oct 2011 00:45:02 +0000 (17:45 -0700)]
Upgrade V8 to 3.7.0

12 years agoFix #1882 zlib Update 'availOutBefore' value, and test
isaacs [Thu, 13 Oct 2011 23:37:49 +0000 (16:37 -0700)]
Fix #1882 zlib Update 'availOutBefore' value, and test

12 years agodocs: add API documentation note about UDP datagram size
Guglielmo Ferri [Sat, 10 Sep 2011 12:55:58 +0000 (15:55 +0300)]
docs: add API documentation note about UDP datagram size

12 years agodocs: document `process.versions`
Maciej Małecki [Thu, 13 Oct 2011 14:10:24 +0000 (16:10 +0200)]
docs: document `process.versions`

12 years agonet: register net.Server callback only once
Simen Brekken [Wed, 12 Oct 2011 10:06:16 +0000 (13:06 +0300)]
net: register net.Server callback only once

Only register once for listening when passing a callback to Server.listen(),
this prevents servers recycled using close() from invoking the callback when
Server.listen() is called later.

12 years agoplatform: support long process names on linux
Ben Noordhuis [Thu, 13 Oct 2011 02:56:11 +0000 (04:56 +0200)]
platform: support long process names on linux

12 years agotest: test long process name support
Ben Noordhuis [Thu, 13 Oct 2011 13:36:28 +0000 (15:36 +0200)]
test: test long process name support

On platforms that support it: linux, freebsd, darwin

12 years agodocs: added .json modules.
koichik [Thu, 13 Oct 2011 08:06:27 +0000 (17:06 +0900)]
docs: added .json modules.

12 years agodocs: mention util instead of sys
Brian White [Thu, 13 Oct 2011 01:20:03 +0000 (22:20 -0300)]
docs: mention util instead of sys

12 years agoFix test-http-conn-reset.js on OSX
Ryan Dahl [Thu, 13 Oct 2011 00:31:32 +0000 (17:31 -0700)]
Fix test-http-conn-reset.js on OSX

12 years agodocs: improved fs.Stats section in API documentation
Ilya Dmitrichenko [Tue, 11 Oct 2011 22:30:29 +0000 (23:30 +0100)]
docs: improved fs.Stats section in API documentation

12 years agosys has been moved to util
Arnout Kazemier [Wed, 12 Oct 2011 18:50:42 +0000 (21:50 +0300)]
sys has been moved to util

12 years agoMove some slow tests to pummel
Ryan Dahl [Wed, 12 Oct 2011 23:59:00 +0000 (16:59 -0700)]
Move some slow tests to pummel

12 years agoFix test/pummel/test-watch-file.js
Ryan Dahl [Wed, 12 Oct 2011 23:18:42 +0000 (16:18 -0700)]
Fix test/pummel/test-watch-file.js

12 years agoFix test/pummel/test-exec.js
Ryan Dahl [Wed, 12 Oct 2011 23:11:55 +0000 (16:11 -0700)]
Fix test/pummel/test-exec.js

12 years agoNew win32 platform function: GetCPUInfo
Karl Skomski [Tue, 6 Sep 2011 19:28:15 +0000 (21:28 +0200)]
New win32 platform function: GetCPUInfo

Fixes #1644

12 years agoImprove IPC performance.
Daniel Ennis [Wed, 12 Oct 2011 00:54:55 +0000 (20:54 -0400)]
Improve IPC performance.

Reading of JSON data off the buffer, 10-15% performance increase.

Fixes #1864.

12 years agoAdd cluster.js to node.gyp
Ryan Dahl [Wed, 12 Oct 2011 21:51:25 +0000 (14:51 -0700)]
Add cluster.js to node.gyp

12 years agoAdd some docs for node cluster
Ryan Dahl [Wed, 12 Oct 2011 21:19:32 +0000 (14:19 -0700)]
Add some docs for node cluster

12 years agoRemove process.ARGV
Ryan Dahl [Wed, 12 Oct 2011 21:10:30 +0000 (14:10 -0700)]
Remove process.ARGV

Use process.argv instead.

12 years agoRevert some changes made in 12486a6
Ryan Dahl [Wed, 12 Oct 2011 19:46:41 +0000 (12:46 -0700)]
Revert some changes made in 12486a6

Some of the perf improvements from many-writes-fix branch were accidentally
undone in that commit. This puts them back in.

12 years agoRemove uname and git-rev detection from http_simple.js
Ryan Dahl [Wed, 12 Oct 2011 19:29:40 +0000 (12:29 -0700)]
Remove uname and git-rev detection from http_simple.js

12 years agoUpgrade libuv to c903bc3
Ryan Dahl [Wed, 12 Oct 2011 19:27:46 +0000 (12:27 -0700)]
Upgrade libuv to c903bc3

12 years agodocs: fix child_process.send() example
Ben Noordhuis [Wed, 12 Oct 2011 15:44:12 +0000 (17:44 +0200)]
docs: fix child_process.send() example

12 years agouv: upgrade to 25a177a
Ben Noordhuis [Wed, 12 Oct 2011 15:32:47 +0000 (17:32 +0200)]
uv: upgrade to 25a177a

Fixes #1869.

12 years agotest: add test for #1869
Ben Noordhuis [Wed, 12 Oct 2011 14:28:46 +0000 (16:28 +0200)]
test: add test for #1869

fs.readdir() on file should raise ENOTDIR, not UNKNOWN.

12 years agoRemove --use-legacy switch from --help section.
Ben Noordhuis [Wed, 12 Oct 2011 13:47:20 +0000 (15:47 +0200)]
Remove --use-legacy switch from --help section.

12 years agointroduce node cluster
Ryan Dahl [Wed, 12 Oct 2011 09:56:29 +0000 (02:56 -0700)]
introduce node cluster

12 years agofix simple/test-fs-utimes.js on windows
Igor Zinkovsky [Wed, 12 Oct 2011 05:34:51 +0000 (22:34 -0700)]
fix simple/test-fs-utimes.js on windows

12 years agoAdd throughput benchmark
Ryan Dahl [Wed, 12 Oct 2011 05:40:04 +0000 (22:40 -0700)]
Add throughput benchmark

12 years agofs.watch documentation
Igor Zinkovsky [Tue, 11 Oct 2011 23:01:37 +0000 (16:01 -0700)]
fs.watch documentation

12 years agoRemove more dead code
Ryan Dahl [Tue, 11 Oct 2011 22:20:09 +0000 (15:20 -0700)]
Remove more dead code

12 years agoRemove process.ENV
Ryan Dahl [Tue, 11 Oct 2011 22:17:32 +0000 (15:17 -0700)]
Remove process.ENV

12 years agoRemove stdio binding source - somehow this was missed in cdf5d91
Ryan Dahl [Tue, 11 Oct 2011 21:59:39 +0000 (14:59 -0700)]
Remove stdio binding source - somehow this was missed in cdf5d91

12 years agoFix test-module-load-list.js
Ryan Dahl [Tue, 11 Oct 2011 21:49:39 +0000 (14:49 -0700)]
Fix test-module-load-list.js