| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
Runs in 3 seconds.
|
| |
|
|
|
|
|
| |
Also removes functionality added in f9fec3a2d65580b7e39edc9afd5904cd4775c87c
because it changes API. (That patch shouldn't have been added anyway.)
|
|
|
|
|
|
| |
Coerce fractional, negative and non-numeric length arguments to numbers.
Fractional numbers are rounded up, negative numbers and non-numeric values
are set to zero.
|
|
|
|
|
|
|
| |
If hasOwnProperty is overridden, then calling `obj.hasOwnProperty(prop)`
can fail. Any time a dictionary of user-generated items is built, we
cannot rely on hasOwnProperty being safe, so must call it from the
Object.prototype explicitly.
|
| |
|
|
|
|
| |
Test case for #1569. Verify that http_parser parses multi-line headers.
|
|
|
|
| |
Fixes #1586.
|
|
|
|
| |
Refs #1633.
|
|
|
|
| |
Fixes #1624.
|
|
|
|
|
|
|
| |
An overloaded toString() method may have side effects
so don't call it for a simple type check.
Back-port of 54b409d to the v0.4 branch.
|
|
|
|
| |
Backported from master f5db3f1f859427d2b1252f937a45409c5d4eb38b
|
| |
|
| |
|
|
|
|
|
| |
Fixes #1417.
Fixes #1223.
|
|
|
|
|
| |
Fixes #738.
Fixes #1205.
|
|
|
|
| |
Fixes #1374.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
During write(), _hasBody is checked to make sure a body
is allowed -- this is now also checked during end(body)
when write() isn't used.
Concise final chunk for HEAD req's res.end(data).
Instead of simply clearing data, check _hasBody
earlier to avoid sending cruft when chunkedEncoding
is used.
Fixes #1291.
|
|
|
|
| |
Fixes #1327.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Reproduce:
$ node
> buf = new Buffer('\0')
<Buffer >
> buf.length
0
> buf = new Buffer(1)
<Buffer 28>
> buf.write('\0')
0
Fixes #394.
Fixes #1210.
|
|
|
|
| |
Fixes #217.
|
| |
|
| |
|
|
|
|
|
| |
Unbreaks test/simple/test-http-get-pipeline-problem.js,
it assumed a fixed number of files in the tmp directory.
|
|
|
|
| |
Thanks to Yann Biancheri for putting together an initial test.
|
|
|
|
|
|
|
|
|
|
|
|
| |
With -e or --eval, require() can load module using relative path.
node -e 'require("./foo")'
But it can't load module from node_modules directory.
node -e 'require("foo")'
Fixes #1196.
|
|
|
|
| |
to better support certain project structures.
|
|
|
|
| |
Fixes #1166.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The file:// protocol *always* has a hostname; it's frequently
abbreviated as an empty string, which represents 'localhost'
implicitly.
According to RFC 1738 (http://tools.ietf.org/html/rfc1738):
A file URL takes the form:
file://<host>/<path>
where <host> is the fully qualified domain name of the system on
which the <path> is accessible...
As a special case, <host> can be the string "localhost" or the empty
string; this is interpreted as 'the machine from which the URL is
being interpreted'.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Problem: Since stream.pipe() is registering it's own error handlers on
the source and destination stream, it needs to replicate the
EventEmitter 'error' emitting semantics of throwing an error if there
are no other listeners. However, there was a off-by-one error because
the check for remaining listeners was done after cleanup() which means
the pipe's own listener was no longer included.
This would cause 'error' events on either the dest or the source to
throw if there was one other error listener, and while swallowing
the 'error' event if there was no other listener.
Solution: I added a test demonstrating the two issues and fixed the
problem by correcting the off-by-one error.
Fixes #1095.
|
|
|
|
| |
Fixes #1069
|
| |
|
| |
|
| |
|
|
|
|
|
| |
Don't write large characters to buffers with binary encoding. You will be
silently injured.
|
|
|
|
| |
Fixes #1038
|
|
|
|
| |
Fixes #1041.
|
|
|
|
|
|
|
|
|
|
|
| |
Problem: It was not possible to detect the reason for a premature
connection termination in http requests.
This patch provides a new `err` argument to the 'close' event which
can be inspected to differentiate between a timeout and a client
actively terminating the connection.
Also contains tests for this new behavior for http and https.
|
|
|
|
| |
Also adds a test case for it.
|
|
|
|
|
|
|
|
| |
The change for #954 introduced a regression that would cause
the url parser to fail on special chars found in the auth
segment. Fix that, and also don't create invalid urls when
format() is called on an object containing an auth member
containing '@' characters or delimiters.
|
|
|
|
|
|
| |
This fixes a critical bug see in MJR's production. Very difficult to build a
test case. Sometimes HTTPS server gets sockets that are hanging in a
half-duplex state.
|
| |
|
|
|
|
| |
Also, tests for the same.
|
| |
|
| |
|
|
|
|
| |
fixes #897.
|
|
|
|
|
|
|
|
| |
1. Allow single-quotes in urls, but escape them.
2. Add comments about which RFCs we're following for guidance.
3. Handle any invalid character in the hostname portion.
4. lcase protocol and hostname portions, since they are
case-insensitive.
|
|
|
|
|
|
|
|
|
|
| |
When creating multiple .pipe()s to the same destination stream, the
first source to end would close the destination, breaking all remaining
pipes. This patch fixes the problem by keeping track of all open
pipes, so that we only call end on destinations that have no more
sources piping to them.
closes #929
|
| |
|