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

947 Commits

Author SHA1 Message Date
Ryan Dahl
c2a62951f6 TLS sockets should not be writable after 'end'
Closes GH-694.
2011-02-19 18:25:15 -08:00
isaacs
8b9dbdad27 Closes GH-687 Don't read fs read stream if not open 2011-02-19 16:38:21 -08:00
isaacs
f8defa3e09 package.json main as indexed subdir
Closes GH-686.
2011-02-18 10:43:06 -08:00
Ryan Dahl
aac5cbe025 HTTP Agent sockets should not reconnect on error
Closes GH-684.
2011-02-18 10:40:09 -08:00
Ryan Dahl
9b0c7618c5 HTTP Agent should not die on evil server
Closes GH-680.
2011-02-18 00:42:07 -08:00
Ryan Dahl
19b4c27ebf TLS: Make _cycle reentrant. 2011-02-16 18:10:53 -08:00
Ryan Dahl
c365f56061 https was missing 'end' event sometimes
Closes GH-671.
2011-02-15 17:13:53 -08:00
Felix Geisendörfer
e56ee67e13 Refactor fs.open parameter handling
Improvements:
* Removes an unnecessary variable
* Avoids having two variables with the same name
* Avoids re-declaring an existing parameter
* Removes an unnecessary ternary operator
* Avoid an inline short-circuit expression for greater clarity.
2011-02-15 13:57:54 -08:00
Felix Geisendörfer
29b0dc4ec8 Fix: fs.open callback did not fire
Problem: Omitting the mode parameter causes the provided callback
parameter to never fire. This was originally fixed in 6078c37b and
later broken in 5f2e9093.

Solution: Overwriting the value of a parameter also overwrites the
reference in the arguments object. This patch works arround this
fact by not touching the mode parameter until a reference to the
callback has been established.
2011-02-15 13:50:59 -08:00
Ryan Dahl
77ae87d367 default to port 80 for http.request 2011-02-15 12:08:26 -08:00
Richard Rodger
b11d78b386 Fix for DNS fail in HTTP request
Closes GH-653.
2011-02-14 16:36:23 -08:00
isaacs
f07041e6cd Make the repl respect node_modules folders.
This is important so that in the future, this will work:

    $ cd ~/dev/js/some-project
    $ npm install redis
    $ node
    > require.resolve('redis')
    '/Users/isaacs/dev/js/some-project/node_modules/redis/index.js'
2011-02-14 13:43:22 -08:00
Tj Holowaychuk
fe838611f6 Fixed field merging with progressive fields on writeHead() 2011-02-14 13:40:31 -08:00
Tim Caswell
b09c5889be Add support for mutable/implicit headers for http.
This works for both ServerResponse and ClientRequest.
Adds three new methods as a couple properties to to OutgoingMessage objects.
Tests by Charlie Robbins.

Change-Id: Ib6f3829798e8f11dd2b6136e61df254f1564807e
2011-02-10 02:31:41 -08:00
Theo Schlossnagle
01a864a29d TLS: CRL support
Needs more tests.
2011-02-10 00:49:15 -08:00
Mikeal Rogers
634e7236f7 Add 'pipe' event 2011-02-09 23:04:35 -08:00
Ryan Dahl
e9257b859d New DTrace probes from CA team 2011-02-09 18:50:26 -08:00
isaacs
46513483cd node_modules module lookup, +docs and test. 2011-02-09 14:24:22 -08:00
Ryan Dahl
dafd6d9137 TLS: Don't give up if you can't write 0 bytes 2011-02-09 13:27:23 -08:00
Ryan Dahl
a48a075535 better debug messages in net and tls 2011-02-09 10:23:26 -08:00
Bert Belder
8d70294c31 Fix fs.realpathSync on windows 2011-02-08 21:24:30 -08:00
isaacs
9bed5dcb2c Support caching for realpath, use in module load
This adds support for a cache object to be passed to the
fs.realpath and fs.realpathSync functions.  The Module loader keeps an
object around which caches the resulting realpaths that it looks up in
the process of loading modules.

This means that (at least as a result of loading modules) the same files
and folders are never lstat()ed more than once.  To reset the cache, set
require("module")._realpathCache to an empty object.  To disable the
caching behavior, set it to null.
2011-02-08 18:02:59 -08:00
Ryan Dahl
9de5043b50 tls: only emit data after 'secure' event 2011-02-08 17:29:33 -08:00
Bert Belder
38d8cd60ea Don't make unnecessary getcwd calls from path.resolve 2011-02-08 14:30:24 -08:00
Ryan Dahl
448e0f4394 tls fixes 2011-02-07 21:11:43 -08:00
Bert Belder
61af4207da Fix dns on windows 2011-02-07 15:30:17 -08:00
isaacs
2e6a263e29 Closes GH-609 Support array-ish args to Buffer ctor
Any array-ish thing (whether a Buffer, an Array, or just an object with
a numeric "length") is interpreted as a list of bytes.
2011-02-07 14:13:18 -08:00
isaacs
5f2e90934e Support octal strings for modes
This allows the various fs utilities and process.umask to be used in
ECMAScript 5 Strict Mode, where the octal literal format is verboten,
without requiring users to litter their code with a bunch of parseInt
calls.
2011-02-07 14:05:06 -08:00
Konstantin Käfer
9e101f2b01 UCS-2 support
Closes GH-644.
2011-02-07 13:35:06 -08:00
Russell Haering
e6ede31554 http: fix buffer writes to outgoing messages 2011-02-07 12:59:25 -08:00
isaacs
da2f4b2dc4 support for package.json
This adds basic support for situations where there is a package.json
with a "main" field.  That "main" module is used as the code that is
loaded when the package folder is required.
2011-02-07 11:00:22 -08:00
Mikeal Rogers
2b03ba5917 http: agent takes options instead of host, port pair 2011-02-05 02:35:44 -08:00
Ryan Dahl
4733d0b1f0 http: handle aborts 2011-02-04 18:07:00 -08:00
Ryan Dahl
1a7830a92a Fix debug flag in timers.js 2011-02-04 09:00:21 -08:00
isaacs
2f1f22ab26 module: define functions only once. 2011-02-03 14:23:28 -08:00
Ryan Dahl
f6e5b8986f Clean up 2011-02-03 12:28:20 -08:00
Ryan Dahl
97f7c06451 TLS: fix throttling
Re-enable test-https-large-response.js

Closes GH-614.
2011-02-03 12:20:19 -08:00
Ryan Dahl
3e58696c07 TLS: Simplify error handling 2011-02-02 15:39:03 -08:00
Ryan Dahl
41b4ec7952 TLS: flush buffer before destroy
Also disable test-https-large-response.js. Covered by
test/simple/test-tls-throttle.js
2011-02-02 15:34:21 -08:00
Ryan Dahl
e6f14d6df5 (suck, blow) -> (pull, push) 2011-02-02 14:51:53 -08:00
isaacs
f86ec1366f Closes GH-619 Make require.main be the main module 2011-02-02 11:18:34 -08:00
Ryan Dahl
2ff593ad23 TLS: better error reporting at binding layer
Closes GH-612.
2011-02-01 14:14:50 -08:00
Joe Walnes
df6e497793 dgram: setMulticastTTL, setMulticastLoopback and addMembership.
These are options needed for real-world multicasting.

Implementation notes:
- POSIX only.
- IPv4 only (IPv6 multicast is a tricky beast).
- Didn't update tests, because it can't effectively be demonstrated on
  localhost only.
2011-02-01 10:16:48 -08:00
Ryan Dahl
3e5b568504 TLS: Add _pendingBytes() 2011-01-31 17:29:11 -08:00
Ryan Dahl
45b30a879b tls: superficial clean up 2011-01-31 16:37:29 -08:00
Ryan Dahl
9f3a20c76d net: Add hook for when writeQueue changes 2011-01-31 11:01:59 -08:00
Ryan Dahl
6ede26cb9c Add socket.bufferSize 2011-01-31 10:41:52 -08:00
Ryan Dahl
192d2e0803 REPL: disable colors in windows for now 2011-01-28 12:58:19 -08:00
Ryan Dahl
df5d5d6342 Fix option parsing in tls.connect() 2011-01-27 19:25:08 -08:00
Ryan Dahl
cb06abe1e5 Helpful error when child_process.exec hit maxBuffer 2011-01-27 17:45:17 -08:00