platform/upstream/nodejs.git
13 years agoAdded documentation for which module to require to use the methods defined in that...
Micheil Smith [Sun, 14 Nov 2010 12:51:32 +0000 (23:51 +1100)]
Added documentation for which module to require to use the methods defined in that documentation

13 years agoA few changes to the style, specifically for h3 + h3
Micheil Smith [Sun, 14 Nov 2010 12:50:48 +0000 (23:50 +1100)]
A few changes to the style, specifically for h3 + h3

13 years agoVarious changes to Net Documentation, ammended style for API.
Micheil Smith [Sun, 14 Nov 2010 10:12:04 +0000 (21:12 +1100)]
Various changes to Net Documentation, ammended style for API.

13 years agowriteFile fixes
isaacs [Sun, 14 Nov 2010 04:12:47 +0000 (20:12 -0800)]
writeFile fixes

writeFileSync could exhibit pathological behavior when a buffer could
not be written to the file in a single write() call.

Also, writeFile was not quite as optimized as it could be.

13 years agoUse require('javascript') instead of process.binding('evals')
Ryan Dahl [Sat, 13 Nov 2010 23:18:10 +0000 (15:18 -0800)]
Use require('javascript') instead of process.binding('evals')

13 years agoRemove process.compile from docs
Ryan Dahl [Sat, 13 Nov 2010 23:08:09 +0000 (15:08 -0800)]
Remove process.compile from docs

13 years agoUpdate gitignore for new docs
Ryan Dahl [Sat, 13 Nov 2010 23:02:18 +0000 (15:02 -0800)]
Update gitignore for new docs

13 years agofix 'make doc'
Ryan Dahl [Sat, 13 Nov 2010 22:57:35 +0000 (14:57 -0800)]
fix 'make doc'

13 years agoFix V8 build on Cygwin
Bert Belder [Thu, 11 Nov 2010 22:08:26 +0000 (23:08 +0100)]
Fix V8 build on Cygwin

13 years agoAdd --profile flag to configure script, enables gprof profiling.
Ben Noordhuis [Sat, 13 Nov 2010 11:58:24 +0000 (12:58 +0100)]
Add --profile flag to configure script, enables gprof profiling.

13 years agoAdded support for cross compilation and also fixed DEST_CPU to represent the canonica...
Rasmus Andersson [Sun, 24 Oct 2010 14:15:05 +0000 (16:15 +0200)]
Added support for cross compilation and also fixed DEST_CPU to represent the canonical symbols dictated by v8

13 years agoFix segfault on test-crypto
Ryan Dahl [Sat, 13 Nov 2010 22:26:40 +0000 (14:26 -0800)]
Fix segfault on test-crypto

Plus random cleanups. This code needs help.

13 years agoSimplify REPL displayPrompt
Ryan Dahl [Fri, 12 Nov 2010 22:37:05 +0000 (14:37 -0800)]
Simplify REPL displayPrompt

Now that we insert \r into the stream and aren't switching back and forth
between termios modes, not need to worry about when to display the prompt.

13 years agoUpgrade V8 to 2.5.6
Ryan Dahl [Fri, 12 Nov 2010 06:42:06 +0000 (22:42 -0800)]
Upgrade V8 to 2.5.6

13 years agoAdd writeFilter when in the readline
Ryan Dahl [Fri, 12 Nov 2010 06:36:39 +0000 (22:36 -0800)]
Add writeFilter when in the readline

Switch \n with \r\n for all strings printed out.
Necessary for writev patch.

13 years agoMove ev_loop out of javascript
Ryan Dahl [Fri, 12 Nov 2010 00:33:21 +0000 (16:33 -0800)]
Move ev_loop out of javascript

13 years agojoyent-ize website
Ryan Dahl [Tue, 9 Nov 2010 23:43:52 +0000 (15:43 -0800)]
joyent-ize website

13 years agoRemove -e from echo in test. Non-portable
Ryan Dahl [Thu, 11 Nov 2010 06:32:26 +0000 (22:32 -0800)]
Remove -e from echo in test. Non-portable

13 years agoUpgrade http-parser again
Ryan Dahl [Thu, 11 Nov 2010 06:12:47 +0000 (22:12 -0800)]
Upgrade http-parser again

13 years agoUpgrade http-parser
Ryan Dahl [Tue, 9 Nov 2010 21:49:03 +0000 (13:49 -0800)]
Upgrade http-parser

13 years agoRemove util.print from docs
Ryan Dahl [Mon, 8 Nov 2010 01:22:36 +0000 (17:22 -0800)]
Remove util.print from docs

Use process.stdout.write()

13 years agoSet FD_CLOEXEC flag on stdio FDs before spawning.
Guillaume Tuton [Sun, 7 Nov 2010 14:34:20 +0000 (15:34 +0100)]
Set FD_CLOEXEC flag on stdio FDs before spawning.

With regression test.

13 years agoRemove unnecessary ref/unref in iowatcher cb
Ryan Dahl [Sat, 6 Nov 2010 00:38:02 +0000 (17:38 -0700)]
Remove unnecessary ref/unref in iowatcher cb

13 years agoMake writes to process.env update the real environment. Tests included.
Ben Noordhuis [Fri, 15 Oct 2010 13:48:34 +0000 (15:48 +0200)]
Make writes to process.env update the real environment. Tests included.

13 years agoInstall node-waf
Ryan Dahl [Wed, 3 Nov 2010 16:02:19 +0000 (09:02 -0700)]
Install node-waf

13 years agoRemove warning in 'sys' - too aggressive
Ryan Dahl [Wed, 3 Nov 2010 04:20:28 +0000 (21:20 -0700)]
Remove warning in 'sys' - too aggressive

13 years agoAdd legacy methods to Buffer
Ryan Dahl [Tue, 2 Nov 2010 17:09:59 +0000 (10:09 -0700)]
Add legacy methods to Buffer

13 years agoAdd test for http-buffer problem
Ryan Dahl [Tue, 2 Nov 2010 01:23:13 +0000 (18:23 -0700)]
Add test for http-buffer problem

Already fixed in 7e24a05cba2373c0ab1f0629366b664a593f357f

13 years agoBack to WAF
Ryan Dahl [Mon, 1 Nov 2010 23:03:32 +0000 (16:03 -0700)]
Back to WAF

Too much instability right now. Hopefully we can revisit autoconf soon.

13 years agoRemove old buffer api
Ryan Dahl [Mon, 1 Nov 2010 21:59:30 +0000 (14:59 -0700)]
Remove old buffer api

13 years agoAdd missing require('fs')
Ryan Dahl [Mon, 1 Nov 2010 21:56:21 +0000 (14:56 -0700)]
Add missing require('fs')

13 years agoUpgrade V8 to 2.5.3
Ryan Dahl [Mon, 1 Nov 2010 21:10:35 +0000 (14:10 -0700)]
Upgrade V8 to 2.5.3

13 years agoAdd execinfo to freebsd LINKFLAGS
Ryan Dahl [Mon, 1 Nov 2010 18:40:11 +0000 (11:40 -0700)]
Add execinfo to freebsd LINKFLAGS

13 years agoFix 'undefined symbol' errors when loading native modules.
Ben Noordhuis [Mon, 1 Nov 2010 19:34:11 +0000 (20:34 +0100)]
Fix 'undefined symbol' errors when loading native modules.

13 years agoAdd node headers installation
Oleg Efimov [Fri, 29 Oct 2010 14:10:37 +0000 (18:10 +0400)]
Add node headers installation

13 years agoAdd DESTDIR support to Makefile
Oleg Efimov [Fri, 29 Oct 2010 13:07:27 +0000 (17:07 +0400)]
Add DESTDIR support to Makefile

13 years agoRemoved range read optimization as it doesn't work with libeio.
Chandra Sekar S [Sat, 30 Oct 2010 10:06:59 +0000 (15:36 +0530)]
Removed range read optimization as it doesn't work with libeio.

13 years agoClean up 'make clean'
Ryan Dahl [Mon, 1 Nov 2010 02:31:22 +0000 (19:31 -0700)]
Clean up 'make clean'

13 years agoImproper use of CFLAGS
Ryan Dahl [Sun, 31 Oct 2010 00:03:12 +0000 (17:03 -0700)]
Improper use of CFLAGS

13 years agoAdd configure --enable-debug to make it build both
Ryan Dahl [Sat, 30 Oct 2010 23:10:55 +0000 (16:10 -0700)]
Add configure --enable-debug to make it build both

13 years agoDe-indent dns.lookup
Ryan Dahl [Sat, 30 Oct 2010 20:31:51 +0000 (13:31 -0700)]
De-indent dns.lookup

13 years agoMake sure watcher.set() isn't being called when active
Ryan Dahl [Sat, 30 Oct 2010 19:52:53 +0000 (12:52 -0700)]
Make sure watcher.set() isn't being called when active

13 years agoFix argv[6] comment in node_file
Ryan Dahl [Sat, 30 Oct 2010 19:04:30 +0000 (12:04 -0700)]
Fix argv[6] comment in node_file

13 years agoRewrite libeio After callback to use req->result instead of req->errorno for error...
Micheil Smith [Sat, 30 Oct 2010 17:01:46 +0000 (04:01 +1100)]
Rewrite libeio After callback to use req->result instead of req->errorno for error checking

13 years agoDelete libv8 in 'make clean'
Ryan Dahl [Sat, 30 Oct 2010 18:13:55 +0000 (11:13 -0700)]
Delete libv8 in 'make clean'

13 years agoUpgrade V8 to 2.5.2
Ryan Dahl [Sat, 30 Oct 2010 18:13:37 +0000 (11:13 -0700)]
Upgrade V8 to 2.5.2

13 years agoChanges to compile on solaris
Ryan Dahl [Fri, 29 Oct 2010 23:49:39 +0000 (23:49 +0000)]
Changes to compile on solaris

13 years agoHandle null values in clearTimeout
Ryan Dahl [Fri, 29 Oct 2010 07:00:43 +0000 (00:00 -0700)]
Handle null values in clearTimeout

13 years agoInstall node-waf
Ryan Dahl [Fri, 29 Oct 2010 02:43:00 +0000 (19:43 -0700)]
Install node-waf

13 years agoX the node-repl script
Ryan Dahl [Fri, 29 Oct 2010 02:41:44 +0000 (19:41 -0700)]
X the node-repl script

13 years agoDisable make manpage, this is broken and can prevent node from installing correctly.
Micheil Smith [Thu, 28 Oct 2010 23:52:33 +0000 (10:52 +1100)]
Disable make manpage, this is broken and can prevent node from installing correctly.

13 years agoFix make doc
Ryan Dahl [Thu, 28 Oct 2010 22:10:20 +0000 (15:10 -0700)]
Fix make doc

13 years agoRemoving the old doc templates, and doc javascript
Micheil Smith [Thu, 28 Oct 2010 22:00:16 +0000 (09:00 +1100)]
Removing the old doc templates, and doc javascript

13 years agoMore simplification of the templating & rendering.
Micheil Smith [Thu, 28 Oct 2010 20:00:28 +0000 (07:00 +1100)]
More simplification of the templating & rendering.

13 years agoAdded a single page version, moved index to be standard page.
Micheil Smith [Thu, 28 Oct 2010 19:50:53 +0000 (06:50 +1100)]
Added a single page version, moved index to be standard page.

13 years agoAdding build tools & templates/assets
Micheil Smith [Thu, 28 Oct 2010 12:18:54 +0000 (23:18 +1100)]
Adding build tools & templates/assets

13 years agoSplitting documentation
Micheil Smith [Thu, 28 Oct 2010 12:18:16 +0000 (23:18 +1100)]
Splitting documentation

13 years agoLazy load modules in net.js
Ryan Dahl [Thu, 28 Oct 2010 20:15:53 +0000 (13:15 -0700)]
Lazy load modules in net.js

13 years agoRemove a little redundancy
Ryan Dahl [Thu, 28 Oct 2010 20:02:51 +0000 (13:02 -0700)]
Remove a little redundancy

13 years agoHandle one more onReadable call from crypto
Ryan Dahl [Thu, 28 Oct 2010 19:34:46 +0000 (12:34 -0700)]
Handle one more onReadable call from crypto

MUST get rid of this calledByIOWatcher stuff. Hopefully will be able to when
securepair stuff lands.

13 years agoAbstract out a Server.prototype.pause method
Ryan Dahl [Thu, 28 Oct 2010 18:42:22 +0000 (11:42 -0700)]
Abstract out a Server.prototype.pause method

13 years agoAbstract out net.Server.prototype._rejectPending
Ryan Dahl [Thu, 28 Oct 2010 18:33:33 +0000 (11:33 -0700)]
Abstract out net.Server.prototype._rejectPending

Does the same timeout action for maxConnections as it does for EMFILE.

13 years agoModule-level EMFILE handling
Jonas Pfenniger [Thu, 28 Oct 2010 10:02:44 +0000 (12:02 +0200)]
Module-level EMFILE handling

All net servers now share the same dummy socket. The ulimit warning is
throttled for all servers.

13 years agoBuild system improvements: (cross compilation, libnode, etc)
Rasmus Andersson [Mon, 25 Oct 2010 22:44:48 +0000 (00:44 +0200)]
Build system improvements: (cross compilation, libnode, etc)

- utilizing autoconf configure.guess to output canonical $target_{cpu,vendor,os}
- normalizing $target_cpu --> $arch according to v8 naming scheme
- normalizing $target_os --> $platform according to v8 naming scheme
- renamed c-ares platform-arch directories to represent v8 canonical names
- new targets in Makefile: libnode-{static,dynamic}[-debug]
- scons is symbolized as SCONS in Makefile for portability/flexibility.
- LINKFLAGS inherith from LDFLAGS ("magic" variable exported by autoconf and configure).
- When building on OS X, CFLAGS and LDFLAGS will contain appropriate -arch flag, set up by configure (instead of the Makefile).
- libv8.a make targets cleaned up with unison libv8_flags set of flags.
- the clean make target now cleans up libraries (libv8, libnode, etc).
- added config.guess, config.sub and install-sh (utilized by autoconf/configure)

13 years agoHandle cyclic links smarter in fs.realpath
isaacs [Mon, 25 Oct 2010 19:28:53 +0000 (12:28 -0700)]
Handle cyclic links smarter in fs.realpath

Rather than aborting in the face of *any* repeated link in a given path,
instead only abort if such a cycle actually makes a given path unresolvable.

Test for this by doing a normal stat.  Still use the seenLinks object to
cache link contents so as to cut own a little bit on readlink calls.

Also add a pathological test that fails without the change to fs.js.

13 years agoLet exit listeners know the exit code
isaacs [Sat, 23 Oct 2010 23:44:19 +0000 (16:44 -0700)]
Let exit listeners know the exit code

13 years agomake "node --eval" eval in the global scope.
Jorge Chamorro Bieling [Sat, 23 Oct 2010 20:39:25 +0000 (22:39 +0200)]
make "node --eval" eval in the global scope.

13 years agoRefactor callbacks in net.Stream for fewer closures
Ryan Dahl [Wed, 27 Oct 2010 22:29:08 +0000 (15:29 -0700)]
Refactor callbacks in net.Stream for fewer closures

13 years agoAdd extra anti-DoS tech to net.Server
Ryan Dahl [Wed, 27 Oct 2010 19:08:47 +0000 (12:08 -0700)]
Add extra anti-DoS tech to net.Server

13 years agoImprove idle benchmarks
Ryan Dahl [Wed, 27 Oct 2010 09:52:49 +0000 (02:52 -0700)]
Improve idle benchmarks

13 years agoGracefully handle EMFILE
Ryan Dahl [Wed, 27 Oct 2010 09:10:14 +0000 (02:10 -0700)]
Gracefully handle EMFILE

Implementing a tip from Marc Lehmann:
http://pod.tst.eu/http://cvs.schmorp.de/libev/ev.pod#The_special_problem_of_accept_ing_wh

Keep an extra FD around for every server. When you hit EMFILE, destroy that
FD, accept a connection, close it; in this way you can clear the connection
queue and let people know that you're overload.

No more timeout needed.

13 years agoStyle changes.
Tim-Smart [Tue, 26 Oct 2010 04:05:04 +0000 (17:05 +1300)]
Style changes.

13 years agoUse the timer list for setTimeout
Ryan Dahl [Tue, 26 Oct 2010 19:52:31 +0000 (12:52 -0700)]
Use the timer list for setTimeout

13 years agoMove setTimeout and friends into timers module
Ryan Dahl [Tue, 26 Oct 2010 19:14:17 +0000 (12:14 -0700)]
Move setTimeout and friends into timers module

13 years agoMove idle timers into its own module
Ryan Dahl [Tue, 26 Oct 2010 18:56:32 +0000 (11:56 -0700)]
Move idle timers into its own module

13 years agoAdd C++ API for constructing fast buffer from string
Ryan Dahl [Tue, 26 Oct 2010 20:43:58 +0000 (13:43 -0700)]
Add C++ API for constructing fast buffer from string

13 years agoRemove old TODOs
Ryan Dahl [Tue, 26 Oct 2010 18:31:32 +0000 (11:31 -0700)]
Remove old TODOs

13 years agoFix permissions on http.js
Ryan Dahl [Tue, 26 Oct 2010 18:31:01 +0000 (11:31 -0700)]
Fix permissions on http.js

13 years agoRemove old todo
Ryan Dahl [Tue, 26 Oct 2010 08:10:32 +0000 (01:10 -0700)]
Remove old todo

13 years agoallowHalfOpen disabled by default
Ryan Dahl [Tue, 26 Oct 2010 05:04:39 +0000 (22:04 -0700)]
allowHalfOpen disabled by default

Users too often would forget to add

  socket.on('end', function () {
    socket.end();
  });

Which is a mistake. Therefore we default to this behavior and
only optionally let people handle the 'end' case themselves.

13 years agocreate directories during configure
Ryan Dahl [Tue, 26 Oct 2010 02:52:58 +0000 (19:52 -0700)]
create directories during configure

13 years agoexec instead of sh a the configure.real script
Ryan Dahl [Tue, 26 Oct 2010 02:25:49 +0000 (19:25 -0700)]
exec instead of sh a the configure.real script

13 years agomore configure hackery
Ryan Dahl [Tue, 26 Oct 2010 01:33:15 +0000 (18:33 -0700)]
more configure hackery

13 years agoIgnore configure.real
Ryan Dahl [Tue, 26 Oct 2010 01:24:48 +0000 (18:24 -0700)]
Ignore configure.real

13 years agoadd configure
Ryan Dahl [Tue, 26 Oct 2010 01:17:19 +0000 (18:17 -0700)]
add configure

13 years agofix style
Ryan Dahl [Tue, 26 Oct 2010 00:30:08 +0000 (17:30 -0700)]
fix style

13 years agoSet the readable variables on the read/write streams
Paul Querna [Mon, 25 Oct 2010 22:41:58 +0000 (15:41 -0700)]
Set the readable variables on the read/write streams

and add more debug() calls to make it easier to see the flow

13 years agoAdd SecurePair for handling of a ssl/tls stream.
Paul Querna [Mon, 25 Oct 2010 21:50:34 +0000 (14:50 -0700)]
Add SecurePair for handling of a ssl/tls stream.

13 years agoremove old todo.
Paul Querna [Mon, 25 Oct 2010 16:03:19 +0000 (09:03 -0700)]
remove old todo.

13 years agoCentralize error handling in SecureStream
Paul Querna [Thu, 21 Oct 2010 06:40:15 +0000 (23:40 -0700)]
Centralize error handling in SecureStream

and add a start method, to kick off SSL handshaking, without writing a zero
byte buffer

13 years agoAdd make install
isaacs [Mon, 25 Oct 2010 18:22:36 +0000 (11:22 -0700)]
Add make install

13 years agoUpdate node_net.cc to make us of node_constants.cc
Micheil Smith [Sat, 23 Oct 2010 01:28:26 +0000 (12:28 +1100)]
Update node_net.cc to make us of node_constants.cc

also affects dgram which uses a constant from node_net.cc

13 years agoAdd HAVE_OPENSSL flag to makefile
Paul Querna [Mon, 25 Oct 2010 17:27:39 +0000 (10:27 -0700)]
Add HAVE_OPENSSL flag to makefile

13 years agoadd todo about half-open connections
Ryan Dahl [Mon, 25 Oct 2010 03:11:47 +0000 (20:11 -0700)]
add todo about half-open connections

13 years agoRemove test-base64-bigfile
Ryan Dahl [Mon, 25 Oct 2010 02:20:36 +0000 (19:20 -0700)]
Remove test-base64-bigfile

Already tested in test/simple/test-buffer.js. Takes too long, uses too much
memory.

13 years agoReplace WAF with make/autoconf
Ryan Dahl [Mon, 4 Oct 2010 09:11:27 +0000 (02:11 -0700)]
Replace WAF with make/autoconf

13 years agoNow working on v0.3.1
Ryan Dahl [Sat, 23 Oct 2010 23:01:37 +0000 (16:01 -0700)]
Now working on v0.3.1

13 years agobump version to 0.3.0 v0.3.0
Ryan Dahl [Sat, 23 Oct 2010 22:46:58 +0000 (15:46 -0700)]
bump version to 0.3.0

13 years agoRevert "Add some failing tests for path.join"
Ryan Dahl [Sat, 23 Oct 2010 22:35:58 +0000 (15:35 -0700)]
Revert "Add some failing tests for path.join"

This reverts commit 8c0e87f9c333f3519b6d6439099f669a316ed598.

(Revert until fix comes)

13 years agoone more 'listening' race condition
Ryan Dahl [Sat, 23 Oct 2010 21:26:31 +0000 (14:26 -0700)]
one more 'listening' race condition