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

194 Commits

Author SHA1 Message Date
Weijia Wang
11a2ca29ba
errors: migrate _http_outgoing
PR-URL: https://github.com/nodejs/node/pull/14735
Refs: https://github.com/nodejs/node/issues/11273
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
2017-08-14 17:19:19 -04:00
Weijia Wang
bdfbce9241 http_client, errors: migrate to internal/errors
PR-URL: https://github.com/nodejs/node/pull/14423
Refs: https://github.com/nodejs/node/issues/11273
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
2017-08-01 14:08:12 +02:00
Rich Trott
095c0de94d benchmark,lib,test: use braces for multiline block
For if/else and loops where the bodies span more than one line, use
curly braces.

PR-URL: https://github.com/nodejs/node/pull/13828
Ref: https://github.com/nodejs/node/pull/13623#discussion_r123048602
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2017-06-23 14:43:20 -07:00
cjihrig
d0571a926a https: support rejectUnauthorized for unix sockets
This commit allows self signed certificates to work with
unix sockets by forwarding the rejectUnauthorized option.

Fixes: https://github.com/nodejs/node/issues/13470
PR-URL: https://github.com/nodejs/node/pull/13505
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: Sam Roberts <vieuxtech@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
2017-06-08 13:40:20 -04:00
Sam Roberts
3fba3d6409 http: describe parse err in debug output
PR-URL: https://github.com/nodejs/node/pull/13206
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Brian White <mscdex@mscdex.net>
2017-06-01 16:41:29 -07:00
Brian White
3774c99f66
http: fix IPv6 Host header check
PR-URL: https://github.com/nodejs/node/pull/13122
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Refael Ackermann <refack@gmail.com>
2017-05-22 23:04:33 -04:00
Brian White
ed365653f6
http,https: avoid instanceof for WHATWG URL
PR-URL: https://github.com/nodejs/node/pull/12983
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Timothy Gu <timothygu99@gmail.com>
Reviewed-By: Daijiro Wachi <daijiro.wachi@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
2017-05-22 18:07:27 -04:00
Trevor Norris
4a7233c178
lib: implement async_hooks API in core
Implement async_hooks support in the following:

* fatalException handler
* process.nextTick
* Timers
* net/dgram/http

PR-URL: https://github.com/nodejs/node/pull/12892
Ref: https://github.com/nodejs/node/pull/11883
Ref: https://github.com/nodejs/node/pull/8531
Reviewed-By: Andreas Madsen <amwebdk@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Sam Roberts <vieuxtech@gmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
2017-05-10 22:22:29 +02:00
Brian White
e283319969
http: fix permanent deoptimizations
PR-URL: https://github.com/nodejs/node/pull/12456
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2017-04-30 03:17:29 -04:00
James M Snell
85a4e25775 http: add type checking for hostname
Add type checking for options.hostname / options.host
Maintains the use of `undefined` and `null` for default `localhost`,
but other falsy values (like `false`, `0` and `NaN`) are rejected.

PR-URL: https://github.com/nodejs/node/pull/12494
Ref: https://github.com/nodejs/node/issues/12488
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Ali Ijaz Sheikh <ofrobots@google.com>
2017-04-24 10:49:12 -07:00
fengmk2
90403dd1d0 http: should support userland Agent
PR-URL: https://github.com/nodejs/node/pull/11567
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
2017-03-26 13:13:58 -07:00
James M Snell
74c1e02642 http: replace uses of self
PR-URL: https://github.com/nodejs/node/pull/11594
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
2017-03-20 16:01:39 -07:00
James M Snell
5425e0dcbe http: use more efficient module.exports pattern
PR-URL: https://github.com/nodejs/node/pull/11594
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
2017-03-20 16:01:31 -07:00
James M Snell
98e54b0bd4 meta: restore original copyright header
A prior io.js era commit inappropriately removed the
original copyright statements from the source. This
restores those in any files still remaining from that
edit.

Ref: https://github.com/nodejs/TSC/issues/174
Ref: https://github.com/nodejs/node/pull/10599
PR-URL: https://github.com/nodejs/node/pull/10155

Note: This PR was required, reviewed-by and approved
by the Node.js Foundation Legal Committee and the TSC.
There is no `Approved-By:` meta data.
2017-03-10 11:23:48 -08:00
Brian White
940b5303be
http: use Symbol for outgoing headers
PR-URL: https://github.com/nodejs/node/pull/10941
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
2017-03-09 05:50:22 -05:00
Jackson Tian
aa8eb8747c
http: use direct parameters instead
When parameter count is fixed, use literal Array instance is more
simply and avoid arguments leak also.

PR-URL: https://github.com/nodejs/node/pull/10833
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Brian White <mscdex@mscdex.net>
2017-01-31 12:56:21 -05:00
Luigi Pinca
18d4ee97d8 http: make request.abort() destroy the socket
`request.abort()` did not destroy the socket if it was called
before a socket was assigned to the request and the request
did not use an `Agent` or a Unix Domain Socket was used.

Fixes: https://github.com/nodejs/node/issues/10812
PR-URL: https://github.com/nodejs/node/pull/10818
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
2017-01-28 18:04:29 +01:00
brad-decker
fc7025c9c0 http: throw an error for unexpected agent values
As per https://github.com/nodejs/node/issues/9069
unexpected things can happen when supplying an
unexpected value to agent. Beings as the docs
clearly state the expected values, this throws
an error on an unexpected value.

PR-URL: https://github.com/nodejs/node/pull/10053
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Sam Roberts <vieuxtech@gmail.com>
2017-01-18 10:24:28 -05:00
Brian White
2f7759640e
http: misc ClientRequest cleanup
PR-URL: https://github.com/nodejs/node/pull/10654
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Fedor Indutny <fedor.indutny@gmail.com>
2017-01-13 16:11:18 -05:00
Brian White
15c6187aa5
http: avoid duplicate isArray()
PR-URL: https://github.com/nodejs/node/pull/10654
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Fedor Indutny <fedor.indutny@gmail.com>
2017-01-13 16:11:18 -05:00
Brian White
dab22b5b7a
http: optimize default method case
PR-URL: https://github.com/nodejs/node/pull/10654
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Fedor Indutny <fedor.indutny@gmail.com>
2017-01-13 16:11:18 -05:00
Brian White
5c2ef14f21
http: optimize short path validation
PR-URL: https://github.com/nodejs/node/pull/10654
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Fedor Indutny <fedor.indutny@gmail.com>
2017-01-13 16:11:17 -05:00
Brian White
c00e4adbb4
http: optimize header storage and matching
This commit implements two optimizations when working with headers:

* Avoid having to explicitly "render" headers and separately store the
original casing for header names.

* Match special header names using a single regular expression instead
of testing one regular expression per header name.

PR-URL: https://github.com/nodejs/node/pull/10558
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Evan Lucas <evanlucas@me.com>
2017-01-11 12:54:31 -05:00
vitkarpov
a2ea1344ea
http: define all used properties in constructors
Adding all used properties in the constructor makes the hidden class
stable and heap snapshots more verbose.

Refs: https://github.com/nodejs/node/issues/8912
PR-URL: https://github.com/nodejs/node/pull/9116
Reviewed-By: Brian White <mscdex@mscdex.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
2017-01-10 01:33:52 -05:00
James M Snell
0f62ee6963 url: allow use of URL with http.request and https.request
PR-URL: https://github.com/nodejs/node/pull/10638
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Evan Lucas <evanlucas@me.com>
Reviewed-By: Michal Zasso <targos@protonmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
2017-01-09 09:28:11 -08:00
Karl Böhlmark
9a5d47542d http: remove stale timeout listeners
In order to prevent a memory leak when using keep alive, ensure that the
timeout listener for the request is removed when the response has ended.

PR-URL: https://github.com/nodejs/node/pull/9440
Reviewed-By: Evan Lucas <evanlucas@me.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
2016-12-08 16:05:22 -05:00
Luca Maraschi
df3978421b http: verify client method is a string
Prior to this commit, it was possible to pass a truthy non-string
value as the HTTP method to the HTTP client, resulting in an
exception being thrown. This commit adds validation to the method.

PR-URL: https://github.com/nodejs/node/pull/10111
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2016-12-08 09:51:07 -05:00
maasencioh
23d6e1f7bc http: name anonymous functions in _http_client
Refs: https://github.com/nodejs/node/issues/8913
PR-URL: https://github.com/nodejs/node/pull/9055
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Franziska Hinkelmann <franziska.hinkelmann@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
2016-10-18 15:38:33 -07:00
Ben Noordhuis
4f62acd9c5 http: reject control characters in http.request()
Unsanitized paths containing line feed characters can be used for
header injection and request splitting so reject them with an exception.

There seems to be no reasonable use case for allowing control characters
(characters <= 31) while there are several scenarios where they can be
used to exploit software bugs so reject control characters altogether.

PR-URL: https://github.com/nodejs/node/pull/8923
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Evan Lucas <evanlucas@me.com>
Reviewed-By: Fedor Indutny <fedor@indutny.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: not-an-aardvark <not-an-aardvark@users.noreply.github.com>
2016-10-13 13:32:45 +02:00
Rene Weber
c9b59e8387 http: socket connection timeout for http request
This allows passing the socket connection timeout to http#request
such that it will be set before the socket is connecting

PR-URL: https://github.com/nodejs/node/pull/8101
Fixes: https://github.com/nodejs/node/issues/7580
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ilkka Myller <ilkka.myller@nodefield.com>
2016-09-26 13:33:52 +03:00
Fedor Indutny
1004ece889 http: wait for both prefinish/end to keepalive
When `free`ing the socket to be reused in keep-alive Agent wait for
both `prefinish` and `end` events. Otherwise the next request may be
written before the previous one has finished sending the body, leading
to a parser errors.

PR-URL: https://github.com/nodejs/node/pull/7149
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2016-06-06 13:34:11 -04:00
Fedor Indutny
9d4d529517 http: skip body and next message of CONNECT res
When handling a response to `CONNECT` request - skip message body
and do not attempt to parse the next message. `CONNECT` requests are
used in similar sense to HTTP Upgrade.

Fix: https://github.com/nodejs/node/pull/6198
PR-URL: https://github.com/nodejs/node/pull/6279
Reviewed-By: Brian White <mscdex@mscdex.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
2016-04-19 11:48:06 -04:00
Mihai Potra
dabe1d5734 http: Corrects IPv6 address in Host header
IPv6 addresses in Host header (URI), must be enclosed within
square brackets, in order to properly separate the host address
from any port reference.

PR-URL: https://github.com/nodejs/node/pull/5314
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Evan Lucas <evanlucas@me.com>
2016-04-01 08:57:16 -07:00
James M Snell
85ab4a5f12 buffer: add .from(), .alloc() and .allocUnsafe()
Several changes:

* Soft-Deprecate Buffer() constructors
* Add `Buffer.from()`, `Buffer.alloc()`, and `Buffer.allocUnsafe()`
* Add `--zero-fill-buffers` command line option
* Add byteOffset and length to `new Buffer(arrayBuffer)` constructor
* buffer.fill('') previously had no effect, now zero-fills
* Update the docs

PR-URL: https://github.com/nodejs/node/pull/4682
Reviewed-By: Сковорода Никита Андреевич <chalkerx@gmail.com>
Reviewed-By: Stephen Belanger <admin@stephenbelanger.com>
2016-03-16 08:34:02 -07:00
Nathan Woltman
d0582ef9e1 lib: copy arguments object instead of leaking it
Instead of leaking the arguments object by passing it as an
argument to a function, copy it's contents to a new array,
then pass the array. This allows V8 to optimize the function
that contains this code, improving performance.

PR-URL: https://github.com/nodejs/node/pull/4361
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Brian White <mscdex@mscdex.net>
2016-03-10 18:45:08 -08:00
Brian White
9bee03aaf2 http: allow async createConnection()
This commit adds support for async createConnection()
implementations and is still backwards compatible with
synchronous createConnection() implementations.

This commit also makes the http client more friendly with
generic stream objects produced by createConnection() by
checking stream.writable instead of stream.destroyed as the
latter is currently a net.Socket-ism and not set by the core
stream implementations.

PR-URL: https://github.com/nodejs/node/pull/4638
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2016-02-11 12:52:46 -05:00
Rich Trott
bbaf0f926d http: remove variable redeclaration
In lib/_http_client.js, the variable `conn` was declared with the `var`
keyword three times in the same scope. This change eliminates the
variable entirely.

PR-URL: https://github.com/nodejs/node/pull/4612
Reviewed-By: Michaël Zasso <mic.besace@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2016-01-11 10:31:45 -08:00
José F. Romaniello
5a2541de81 http: handle errors on idle sockets
This change adds a new event handler to the `error` event of the socket
after it has been used by the http_client.

The purpose of this change is to catch errors on *keep alived*
connections from idle sockets that otherwise will cause an uncaugh error
event on the application.

Fix: #3595
PR-URL: https://github.com/nodejs/node/pull/4482
Reviewed-By: Fedor Indutny <fedor@indutny.com>
2016-01-04 13:35:53 -05:00
Rich Trott
fdeb862f2b lib: remove unused modules
Some files in `lib` were using `require` to load modules that were
subsequently not used in the file. This removes those `require`
statements.

PR-URL: https://github.com/nodejs/node/pull/4396
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2015-12-25 13:05:23 -08:00
Fedor Indutny
32ac3769f5 http: do not emit upgrade on advertisement
Do not emit `upgrade` if the server is just advertising its protocols
support as per RFC 7230 Section 6.7.

    A server MAY send an Upgrade header field in any other response
    to advertise that it implements support for upgrading to the
    listed protocols, in order of descending preference, when
    appropriate for a future request.

Fix: https://github.com/nodejs/node/issues/4334
PR-URL: https://github.com/nodejs/node/pull/4337
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2015-12-17 19:25:43 -05:00
micnic
20285ad177 lib: Consistent error messages in all modules
This commit fixes some error messages that are not consistent with
some general rules which most of the error messages follow.

PR-URL: https://github.com/nodejs/node/pull/3374
Reviewed-By: Roman Reiss <me@silverwind.io>
2015-11-09 20:08:36 +01:00
Sakthipriyan Vairamani
437930c0cc http{s}: don't connect to localhost on invalid URL
If the URL passed to `http{s}.request` or `http{s}.get` is not properly
parsable by `url.parse`, we fall back to use `localhost` and port 80.
This creates confusing error messages like in this question
http://stackoverflow.com/q/32675907/1903116.

This patch throws an error message, if `url.parse` fails to parse the
URL properly.

Previous Discussion: https://github.com/nodejs/node/pull/2966
PR-URL: https://github.com/nodejs/node/pull/2967

Reviewed-By: Сковорода Никита Андреевич <chalkerx@gmail.com>
Reviewed-By: Evan Lucas <evanlucas@me.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2015-10-27 08:47:23 +05:30
James M Snell
6192c9892f http: add checkIsHttpToken check for header fields
Ref: https://github.com/nodejs/node-convergence-archive/issues/13

This adds a new check for header and trailer fields names and method
names to ensure that they conform to the HTTP token rule. If they do
not, a `TypeError` is thrown.

Previously this had an additional `strictMode` option that has been
removed in favor of making the strict check the default (and only)
behavior.

Doc and test case are included.

On the client-side
```javascript
var http = require('http');
var url = require('url');
var p = url.parse('http://localhost:8888');
p.headers = {'testing 123': 123};
http.client(p, function(res) { }); // throws
```

On the server-side
```javascript
var http = require('http');
var server = http.createServer(function(req,res) {
  res.setHeader('testing 123', 123); // throws
  res.end('...');
});
```

Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
Reviewed-By: Trevor Norris <trevnorris@nodejs.org>
Reviewed-By: Сковорода Никита Андреевич <chalkerx@gmail.com>
Reviewed-By: Rod Vagg <rod@vagg.org>
PR-URL: https://github.com/nodejs/node/pull/2526
2015-09-25 08:37:57 -07:00
Sakthipriyan Vairamani
f32a606e37 lib,src: remove usage of events.EventEmitter
The `events` module already exports `EventEmitter` constructor function
So, we don't have to use `events.EventEmitter` to access it.

Refer: https://github.com/nodejs/node/pull/2896

PR-URL: https://github.com/nodejs/node/pull/2921
Reviewed-By: Roman Reiss <me@silverwind.io>
Reviewed-By: Michaël Zasso <mic.besace@gmail.com>
2015-09-23 00:23:08 +05:30
Malcolm Ahoy
79d2c4e1bf http: remove redundant code in _deferToConnect
Logic for calling the passed in socket method and/or callback
was duplicated. This commit refactors the relevant code to
remove the redundancy.

PR-URL: https://github.com/nodejs/node/pull/2769
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Brendan Ashworth <brendan.ashworth@me.com>
2015-09-22 11:04:26 -04:00
Minwoo Jung
f3c3b23d55 doc: fix comments in tls_wrap.cc and _http_client.js
fixed grammatically wrong expressions to make it clear

Reviewed By: James M Snell <jasnell@gmail.com>
PR-URL: https://github.com/nodejs/node/pull/2490
PR-URL: https://github.com/nodejs/node/pull/2489
2015-08-23 09:01:22 -07:00
Sakthipriyan Vairamani
8f58fb92ff events: deprecate static listenerCount function
As per the discussion in #734, this patch deprecates the usage of
`EventEmitter.listenerCount` static function in the docs, and introduces
the `listenerCount` function in the prototype of `EventEmitter` itself.

PR-URL: https://github.com/nodejs/node/pull/2349
Reviewed-By: Trevor Norris <trev.norris@gmail.com>
Reviewed-By: Brian White <mscdex@mscdex.net>
2015-08-20 03:17:08 +05:30
James M Snell
936c9ffb0f doc: multiple documentation updates cherry picked from v0.12
* doc: improve http.abort description
 * doc: mention that mode is ignored if file exists
 * docs: Fix default options for fs.createWriteStream()
 * Documentation update about Buffer initialization
 * doc: add a note about readable in flowing mode
 * doc: Document http.request protocol option
 * doc, comments: Grammar and spelling fixes
 * updated documentation for fs.createReadStream
 * Update child_process.markdown, spelling
 * doc: Clarified read method with specified size argument.
 * docs:events clarify emitter.listener() behavior
 * doc: two minor stream doc improvements
 * doc: clarify Readable._read and Readable.push
 * doc: stream.unshift does not reset reading state
 * doc: readable event clarification
 * doc: additional refinement to readable event

Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ben Noorduis <ben@strongloop.com>
PR-URL: https://github.com/nodejs/io.js/pull/2302
2015-08-05 08:44:55 -07:00
Roman Reiss
b5b8ff117c lib: don't use global Buffer
Port of https://github.com/joyent/node/pull/8603

The race condition present in the original PR didn't occur, so no
workaround was needed.

PR-URL: https://github.com/nodejs/io.js/pull/1794
Reviewed-By: Trevor Norris <trev.norris@gmail.com>
2015-06-11 20:24:44 +02:00
Evan Lucas
d4726cde57 http,net,tls: return this from setTimeout methods
Modifies the setTimeout methods for the following prototypes:

- http.ClientRequest
- http.IncomingMessage
- http.OutgoingMessage
- http.Server
- https.Server
- net.Socket
- tls.TLSSocket

Previously, the above functions returned undefined. They now return
`this`. This is useful for chaining function calls.

PR-URL: https://github.com/nodejs/io.js/pull/1699
Reviewed-By: Roman Reiss <me@silverwind.io>
2015-05-16 07:17:41 +02:00
Rod Vagg
702997c1f0 Revert "url: significantly improve the performance of the url module"
This reverts commit 3fd7fc429c.

It was agreed that this change contained too much potential ecosystem
breakage, particularly around the inability to `delete` properties off a
`Url` object. It may be re-introduced for a later release, along with
better work on ecosystem compatibility.

PR-URL: https://github.com/iojs/io.js/pull/1602
Reviewed-By: Mikeal Rogers <mikeal.rogers@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Forrest L Norvell <forrest@npmjs.com>
Reviewed-By: Chris Dickinson <christopher.s.dickinson@gmail.com>
Reviewed-By: Isaac Z. Schlueter <i@izs.me>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
2015-05-03 20:29:41 -07:00
Petka Antonov
3fd7fc429c url: significantly improve the performance of the url module
(landed by @rvagg)

PR-URL: https://github.com/iojs/io.js/pull/1561
Reviewed-By: Domenic Denicola <domenic@domenicdenicola.com>
Reviewed-By: Rod Vagg <rod@vagg.org>
2015-05-01 23:12:52 -07:00
Brendan Ashworth
718059777c Revert "http: don't bother making a copy of the options"
This reverts commit 06cfff9350.

Reverted because it introduced a regression where (because options were
modified in the later functionality) options.host and options.port would
be overridden with values provided in other, supported ways.

PR-URL: https://github.com/iojs/io.js/pull/1467
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2015-04-18 14:24:09 -07:00
Trevor Norris
10e31ba56c node: allow multiple arguments passed to nextTick
PR-URL: https://github.com/iojs/io.js/pull/1077
Reviewed-by: Colin Ihrig <cjihrig@gmail.com>
2015-04-15 17:02:21 -06:00
Fedor Indutny
1a3ca8223e http_client: ensure empty socket on error
Read all pending data out of the socket on `error` event and ensure that
no `data`/`end` handlers will be invoked on `socket.destroy()`.
Otherwise following assertion happens:

    AssertionError: null == true
        at TLSSocket.socketOnData (_http_client.js:308:3)
        at TLSSocket.emit (events.js:107:17)
        at TLSSocket.Readable.read (_stream_readable.js:373:10)
        at TLSSocket.socketCloseListener (_http_client.js:229:10)
        at TLSSocket.emit (events.js:129:20)
        at TCP.close (net.js:476:12)

Fix: https://github.com/joyent/node/issues/9348
PR-URL: https://github.com/iojs/io.js/pull/1103
Reviewed-By: Rod Vagg <rod@vagg.org>
Reviewed-By: Nicu Micleușanu <micnic90@gmail.com>
2015-03-09 09:25:09 -04:00
Evan Lucas
2ca22aacbd http: emit abort event from ClientRequest
ClientRequest will now emit an abort event the first time abort()
is called.

Semver: Minor
Fixes: https://github.com/joyent/node/issues/9278
PR-URL: https://github.com/iojs/io.js/pull/945
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Chris Dickinson <christopher.s.dickinson@gmail.com>
2015-02-25 16:40:31 -05:00
Glen Keane
5e825d1073 tracing: add lttng support for tracing on linux
This commit adds the ability to enable userspace tracing with lttng
in io.js. It adds tracepoints for all the equivalent dtrace and ETW
tracepoints. To use these tracepoints enable --with-lttng on linux.

PR-URL: https://github.com/iojs/io.js/pull/702
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Ryan Graham <ryan@strongloop.com>
Reviewed-By: Stephen Belanger <admin@stephenbelanger.com>
2015-02-09 18:06:57 +01:00
cjihrig
6ac8bdc0ab lib: reduce util.is*() usage
Many of the util.is*() methods used to check data types
simply compare against a single value or the result of
typeof. This commit replaces calls to these methods with
equivalent checks. This commit does not touch calls to the
more complex methods (isRegExp(), isDate(), etc.).

Fixes: https://github.com/iojs/io.js/issues/607
PR-URL: https://github.com/iojs/io.js/pull/647
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2015-01-31 23:47:29 -05:00
Jonathan Ong
06cfff9350 http: don't bother making a copy of the options
Alternative to https://github.com/iojs/io.js/pull/592. The `options` object is never overwritten, so making a copy is not necessary.

This solves issues such as https://github.com/petkaantonov/urlparser/issues where the options object is created from a constructor.

PR-URL: https://github.com/iojs/io.js/pull/593
Reviewed-By: Stephen Belanger <admin@stephenbelanger.com>
2015-01-24 13:05:27 -08:00
cjihrig
804e7aa9ab lib: use const to define constants
This commit replaces a number of var statements throughout
the lib code with const statements.

PR-URL: https://github.com/iojs/io.js/pull/541
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2015-01-21 16:21:31 -05:00
Yosuke Furukawa
fd30eb2152 src: fix jslint errors
PR-URL: https://github.com/iojs/io.js/pull/449
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2015-01-15 21:21:31 +01:00
isaacs
3e1b1dd4a9 Remove excessive copyright/license boilerplate
The copyright and license notice is already in the LICENSE file.  There
is no justifiable reason to also require that it be included in every
file, since the individual files are not individually distributed except
as part of the entire package.
2015-01-12 15:30:28 -08:00
Ben Noordhuis
21130c7d6f lib: turn on strict mode
Turn on strict mode for the files in the lib/ directory.  It helps
catch bugs and can have a positive effect on performance.

PR-URL: https://github.com/node-forward/node/pull/64
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Fedor Indutny <fedor@indutny.com>
2014-11-22 17:23:30 +01:00
Ben Noordhuis
150d6f1249 lib: http: poison parser references after freeing
Make it a little harder to slip in use-after-free bugs by nulling out
references to the parser object after handing it off to freeParser().

Reviewed-by: Trevor Norris <trev.norris@gmail.com>
2014-09-05 09:34:37 -07:00
Brian White
03e9f84933 lib: remove unused variables
Signed-off-by: Fedor Indutny <fedor@indutny.com>
2014-06-11 20:41:12 -07:00
Nick Muerdter
1df32af74a http: don't default OPTIONS to chunked encoding
Signed-off-by: Trevor Norris <trev.norris@gmail.com>
Signed-off-by: Fedor Indutny <fedor@indutny.com>
2014-06-05 14:36:46 -07:00
Timothy J Fontaine
1bbb3cc00d lint: lib/_http_client.js 2014-05-22 12:55:41 -07:00
Kevin Decker
d0c7d93536 http: Optimize queued client aborts
Avoid sending unsent data and destroying otherwise legitimate sockets
for requests that are aborted while still in the agent queue. This
reduces stress on upstream systems who will likely respond to the
request but client app already knows that it will be dropped on the
floor and also helps avoid killing keep-alive connections.
2014-05-22 10:46:44 -07:00
Yuki KAN
006d42786e lib: use triple equals
Signed-off-by: Trevor Norris <trev.norris@gmail.com>
2014-04-02 02:12:18 -07:00
Nathan Rajlich
6d15b163b0 http: better client "protocol not supported" error
Include the "expected protocol" in the Error message
string, which evaluates to "http:" for the `http`
core module, and "https:" for the `https` module.

Closes #7355.
2014-03-28 11:05:35 -10:00
Nathan Rajlich
9f23fe1141 http: use defaultAgent.protocol in protocol check
Default to the `defaultAgent.protocol` when comparing the
user-specified `options.protocol` string. This is so that
`http.Agent` instances do not need to specify their own
`protocol` field, since we have the relevant information
already from the `defaultAgent`.

Note that the test case could be separately cherry-picked
to the `v0.10` branch, since it already passes correctly.

Fixes #7349.
Fixes the regression described in: http://git.io/2ds-WQ
2014-03-24 12:59:31 -10:00
Fedor Indutny
78d245f5b2 Merge remote-tracking branch 'origin/v0.10'
Conflicts:
	configure
	lib/_stream_readable.js
	lib/http.js
	src/node_dtrace.cc
2014-03-02 23:54:19 +04:00
Nathan Rajlich
d6bbb19f1d http, https: don't depend on globalAgent
For the `request()` and `get()` functions. I could never
really understand why these two functions go through agent
first... Especially since the user could be passing `agent: false`
or a different Agent instance completely, in which `globalAgent`
will be completely bypassed.

Moved the relevant logic from `Agent#request()` into the
`ClientRequest` constructor.

Incidentally, this commit fixes #7012 (which was the original
intent of this commit).
2014-02-26 13:18:54 -08:00
Trevor Norris
828f14556e src: revert domain using AsyncListeners
This is a slightly modified revert of bc39bdd.

Getting domains to use AsyncListeners became too much of a challenge
with many edge cases. While this is still a goal, it will have to be
deferred for now until more test coverage can be provided.
2014-01-09 13:25:20 -08:00
Lalit Kapoor
aef09601b4 http: DELETE shouldn't default to chunked encoding 2013-12-06 16:25:42 -08:00
Fedor Indutny
5ce4eed54d http: fix parser double-free in _http_client.js
HTTP Parser instance was freed twice, leading to the reusal of it
in several different requests simultaneously.

The flow:

`socketCloseListener` is firing, which calls `socket.read()` to flush
any queued data, `socket.buffer` has data which emits and fires
`socketOnData` in sync, this triggers a parser error which frees the
parser, `socketCloseListener` resumes execution only to have the wrong
parser associated with the socket.

The fix is to only cache the parser after the flushing from the socket,
and to assert in `socketOnData` that `socket === parser.socket`

fix #6451
2013-11-27 15:37:56 -08:00
Trevor Norris
bc39bdd995 domain: use AsyncListener API
The domain module has been switched over to use the domain module API as
much as currently possible. There are still some hooks in the
EventEmitter, but hopefully we can remove those in the future.
2013-10-31 16:34:35 -07:00
isaacs
f153d6da45 http client: pull last chunk on socket close
When the socket closes, the client's http incoming message object was
emitting an 'aborted' event if it had not yet been ended.

However, it's possible, when a response is being repeatedly paused and
resumed (eg, if piped to a slow FS write stream), that there will be a
final chunk remaining in the js-land buffer when the socket is torn
down.

When that happens, the socketCloseListener function detects that we have
not yet reached the end of the response message data, and treats this as
an abrupt abort, immediately (and forcibly) ending the incoming message
data stream, and discarding that final chunk of data.

The result is that, for example, npm will have problems because tarballs
are missing a few bytes off the end, every time.

Closes GH-6402
2013-10-23 13:39:05 -07:00
isaacs
15a5a4a945 http: Only send connection:keep-alive if necessary
In cases where the Agent has maxSockets=Infinity, and
keepAlive=false, there's no case where we won't immediately close the
connection after the response is completed.

Since we're going to close it anyway, send a `connection:close` header
rather than a `connection:keep-alive` header.  Still send the
`connection:keep-alive` if the agent will actually reuse the socket,
however.

Closes #5838
2013-09-04 11:19:39 -07:00
Brian White
6d842897c5 lib: remove unused variables and functions 2013-08-15 17:19:17 -07:00
isaacs
967b5dbb45 http: Use streams3 directly, not .ondata/end 2013-08-08 13:01:09 -07:00
Koichi Kobayashi
72ad2c94df https: fix default port
https.get('https://github.com/') should use port 443, not 80.
2013-08-05 12:53:12 -07:00
isaacs
22c68fdc1d src: Replace macros with util functions 2013-08-01 15:08:01 -07:00
Ben Noordhuis
0330bdf519 lib: macro-ify type checks
Increases the grep factor. Makes it easier to harmonize type checks
across the code base.
2013-07-24 21:49:35 +02:00
Timothy J Fontaine
c898704db1 lint: fix _http_client.js after v0.10 merge 2013-07-12 15:18:53 -07:00
Timothy J Fontaine
48c542db52 Merge remote-tracking branch 'upstream/v0.10'
Conflicts:
	AUTHORS
	ChangeLog
	deps/npm/Makefile
	deps/npm/doc/api/npm-commands.md
	deps/npm/doc/api/npm-deprecate.md
	deps/npm/doc/api/npm-init.md
	deps/npm/doc/api/npm-owner.md
	deps/npm/doc/api/npm-publish.md
	deps/npm/doc/api/npm-run-script.md
	deps/npm/doc/cli/npm-adduser.md
	deps/npm/doc/cli/npm-bin.md
	deps/npm/doc/cli/npm-bugs.md
	deps/npm/doc/cli/npm-build.md
	deps/npm/doc/cli/npm-cache.md
	deps/npm/doc/cli/npm-completion.md
	deps/npm/doc/cli/npm-deprecate.md
	deps/npm/doc/cli/npm-docs.md
	deps/npm/doc/cli/npm-edit.md
	deps/npm/doc/cli/npm-explore.md
	deps/npm/doc/cli/npm-help-search.md
	deps/npm/doc/cli/npm-help.md
	deps/npm/doc/cli/npm-init.md
	deps/npm/doc/cli/npm-install.md
	deps/npm/doc/cli/npm-link.md
	deps/npm/doc/cli/npm-ls.md
	deps/npm/doc/cli/npm-outdated.md
	deps/npm/doc/cli/npm-owner.md
	deps/npm/doc/cli/npm-pack.md
	deps/npm/doc/cli/npm-prefix.md
	deps/npm/doc/cli/npm-prune.md
	deps/npm/doc/cli/npm-publish.md
	deps/npm/doc/cli/npm-restart.md
	deps/npm/doc/cli/npm-rm.md
	deps/npm/doc/cli/npm-root.md
	deps/npm/doc/cli/npm-run-script.md
	deps/npm/doc/cli/npm-search.md
	deps/npm/doc/cli/npm-shrinkwrap.md
	deps/npm/doc/cli/npm-start.md
	deps/npm/doc/cli/npm-stop.md
	deps/npm/doc/cli/npm-submodule.md
	deps/npm/doc/cli/npm-tag.md
	deps/npm/doc/cli/npm-test.md
	deps/npm/doc/cli/npm-uninstall.md
	deps/npm/doc/cli/npm-unpublish.md
	deps/npm/doc/cli/npm-update.md
	deps/npm/doc/cli/npm-version.md
	deps/npm/doc/cli/npm-view.md
	deps/npm/doc/cli/npm-whoami.md
	deps/npm/doc/files/npm-folders.md
	deps/npm/doc/files/package.json.md
	deps/npm/doc/misc/npm-coding-style.md
	deps/npm/doc/misc/npm-config.md
	deps/npm/doc/misc/npm-developers.md
	deps/npm/doc/misc/npm-disputes.md
	deps/npm/doc/misc/npm-faq.md
	deps/npm/doc/misc/npm-registry.md
	deps/npm/doc/misc/npm-scripts.md
	deps/npm/doc/misc/semver.md
	deps/npm/html/doc/README.html
	deps/npm/html/doc/api/npm-bin.html
	deps/npm/html/doc/api/npm-bugs.html
	deps/npm/html/doc/api/npm-commands.html
	deps/npm/html/doc/api/npm-config.html
	deps/npm/html/doc/api/npm-deprecate.html
	deps/npm/html/doc/api/npm-docs.html
	deps/npm/html/doc/api/npm-edit.html
	deps/npm/html/doc/api/npm-explore.html
	deps/npm/html/doc/api/npm-help-search.html
	deps/npm/html/doc/api/npm-init.html
	deps/npm/html/doc/api/npm-install.html
	deps/npm/html/doc/api/npm-link.html
	deps/npm/html/doc/api/npm-load.html
	deps/npm/html/doc/api/npm-ls.html
	deps/npm/html/doc/api/npm-outdated.html
	deps/npm/html/doc/api/npm-owner.html
	deps/npm/html/doc/api/npm-pack.html
	deps/npm/html/doc/api/npm-prefix.html
	deps/npm/html/doc/api/npm-prune.html
	deps/npm/html/doc/api/npm-publish.html
	deps/npm/html/doc/api/npm-rebuild.html
	deps/npm/html/doc/api/npm-restart.html
	deps/npm/html/doc/api/npm-root.html
	deps/npm/html/doc/api/npm-run-script.html
	deps/npm/html/doc/api/npm-search.html
	deps/npm/html/doc/api/npm-shrinkwrap.html
	deps/npm/html/doc/api/npm-start.html
	deps/npm/html/doc/api/npm-stop.html
	deps/npm/html/doc/api/npm-submodule.html
	deps/npm/html/doc/api/npm-tag.html
	deps/npm/html/doc/api/npm-test.html
	deps/npm/html/doc/api/npm-uninstall.html
	deps/npm/html/doc/api/npm-unpublish.html
	deps/npm/html/doc/api/npm-update.html
	deps/npm/html/doc/api/npm-version.html
	deps/npm/html/doc/api/npm-view.html
	deps/npm/html/doc/api/npm-whoami.html
	deps/npm/html/doc/api/npm.html
	deps/npm/html/doc/cli/npm-adduser.html
	deps/npm/html/doc/cli/npm-bin.html
	deps/npm/html/doc/cli/npm-bugs.html
	deps/npm/html/doc/cli/npm-build.html
	deps/npm/html/doc/cli/npm-bundle.html
	deps/npm/html/doc/cli/npm-cache.html
	deps/npm/html/doc/cli/npm-completion.html
	deps/npm/html/doc/cli/npm-config.html
	deps/npm/html/doc/cli/npm-dedupe.html
	deps/npm/html/doc/cli/npm-deprecate.html
	deps/npm/html/doc/cli/npm-docs.html
	deps/npm/html/doc/cli/npm-edit.html
	deps/npm/html/doc/cli/npm-explore.html
	deps/npm/html/doc/cli/npm-help-search.html
	deps/npm/html/doc/cli/npm-help.html
	deps/npm/html/doc/cli/npm-init.html
	deps/npm/html/doc/cli/npm-install.html
	deps/npm/html/doc/cli/npm-link.html
	deps/npm/html/doc/cli/npm-ls.html
	deps/npm/html/doc/cli/npm-outdated.html
	deps/npm/html/doc/cli/npm-owner.html
	deps/npm/html/doc/cli/npm-pack.html
	deps/npm/html/doc/cli/npm-prefix.html
	deps/npm/html/doc/cli/npm-prune.html
	deps/npm/html/doc/cli/npm-publish.html
	deps/npm/html/doc/cli/npm-rebuild.html
	deps/npm/html/doc/cli/npm-restart.html
	deps/npm/html/doc/cli/npm-rm.html
	deps/npm/html/doc/cli/npm-root.html
	deps/npm/html/doc/cli/npm-run-script.html
	deps/npm/html/doc/cli/npm-search.html
	deps/npm/html/doc/cli/npm-shrinkwrap.html
	deps/npm/html/doc/cli/npm-star.html
	deps/npm/html/doc/cli/npm-stars.html
	deps/npm/html/doc/cli/npm-start.html
	deps/npm/html/doc/cli/npm-stop.html
	deps/npm/html/doc/cli/npm-submodule.html
	deps/npm/html/doc/cli/npm-tag.html
	deps/npm/html/doc/cli/npm-test.html
	deps/npm/html/doc/cli/npm-uninstall.html
	deps/npm/html/doc/cli/npm-unpublish.html
	deps/npm/html/doc/cli/npm-update.html
	deps/npm/html/doc/cli/npm-version.html
	deps/npm/html/doc/cli/npm-view.html
	deps/npm/html/doc/cli/npm-whoami.html
	deps/npm/html/doc/cli/npm.html
	deps/npm/html/doc/files/npm-folders.html
	deps/npm/html/doc/files/npm-global.html
	deps/npm/html/doc/files/npm-json.html
	deps/npm/html/doc/files/npmrc.html
	deps/npm/html/doc/files/package.json.html
	deps/npm/html/doc/index.html
	deps/npm/html/doc/misc/npm-coding-style.html
	deps/npm/html/doc/misc/npm-config.html
	deps/npm/html/doc/misc/npm-developers.html
	deps/npm/html/doc/misc/npm-disputes.html
	deps/npm/html/doc/misc/npm-faq.html
	deps/npm/html/doc/misc/npm-index.html
	deps/npm/html/doc/misc/npm-registry.html
	deps/npm/html/doc/misc/npm-scripts.html
	deps/npm/html/doc/misc/removing-npm.html
	deps/npm/html/doc/misc/semver.html
	deps/npm/man/man1/npm-README.1
	deps/npm/man/man1/npm-adduser.1
	deps/npm/man/man1/npm-bin.1
	deps/npm/man/man1/npm-bugs.1
	deps/npm/man/man1/npm-build.1
	deps/npm/man/man1/npm-bundle.1
	deps/npm/man/man1/npm-cache.1
	deps/npm/man/man1/npm-completion.1
	deps/npm/man/man1/npm-dedupe.1
	deps/npm/man/man1/npm-deprecate.1
	deps/npm/man/man1/npm-docs.1
	deps/npm/man/man1/npm-edit.1
	deps/npm/man/man1/npm-explore.1
	deps/npm/man/man1/npm-help-search.1
	deps/npm/man/man1/npm-help.1
	deps/npm/man/man1/npm-init.1
	deps/npm/man/man1/npm-install.1
	deps/npm/man/man1/npm-link.1
	deps/npm/man/man1/npm-ls.1
	deps/npm/man/man1/npm-outdated.1
	deps/npm/man/man1/npm-owner.1
	deps/npm/man/man1/npm-pack.1
	deps/npm/man/man1/npm-prefix.1
	deps/npm/man/man1/npm-prune.1
	deps/npm/man/man1/npm-publish.1
	deps/npm/man/man1/npm-rebuild.1
	deps/npm/man/man1/npm-restart.1
	deps/npm/man/man1/npm-rm.1
	deps/npm/man/man1/npm-root.1
	deps/npm/man/man1/npm-run-script.1
	deps/npm/man/man1/npm-search.1
	deps/npm/man/man1/npm-shrinkwrap.1
	deps/npm/man/man1/npm-star.1
	deps/npm/man/man1/npm-stars.1
	deps/npm/man/man1/npm-start.1
	deps/npm/man/man1/npm-stop.1
	deps/npm/man/man1/npm-submodule.1
	deps/npm/man/man1/npm-tag.1
	deps/npm/man/man1/npm-test.1
	deps/npm/man/man1/npm-uninstall.1
	deps/npm/man/man1/npm-unpublish.1
	deps/npm/man/man1/npm-update.1
	deps/npm/man/man1/npm-version.1
	deps/npm/man/man1/npm-view.1
	deps/npm/man/man1/npm-whoami.1
	deps/npm/man/man1/npm.1
	deps/npm/man/man3/npm-bin.3
	deps/npm/man/man3/npm-bugs.3
	deps/npm/man/man3/npm-commands.3
	deps/npm/man/man3/npm-config.3
	deps/npm/man/man3/npm-deprecate.3
	deps/npm/man/man3/npm-docs.3
	deps/npm/man/man3/npm-edit.3
	deps/npm/man/man3/npm-explore.3
	deps/npm/man/man3/npm-help-search.3
	deps/npm/man/man3/npm-init.3
	deps/npm/man/man3/npm-install.3
	deps/npm/man/man3/npm-link.3
	deps/npm/man/man3/npm-load.3
	deps/npm/man/man3/npm-ls.3
	deps/npm/man/man3/npm-outdated.3
	deps/npm/man/man3/npm-owner.3
	deps/npm/man/man3/npm-pack.3
	deps/npm/man/man3/npm-prefix.3
	deps/npm/man/man3/npm-prune.3
	deps/npm/man/man3/npm-publish.3
	deps/npm/man/man3/npm-rebuild.3
	deps/npm/man/man3/npm-restart.3
	deps/npm/man/man3/npm-root.3
	deps/npm/man/man3/npm-run-script.3
	deps/npm/man/man3/npm-search.3
	deps/npm/man/man3/npm-shrinkwrap.3
	deps/npm/man/man3/npm-start.3
	deps/npm/man/man3/npm-stop.3
	deps/npm/man/man3/npm-submodule.3
	deps/npm/man/man3/npm-tag.3
	deps/npm/man/man3/npm-test.3
	deps/npm/man/man3/npm-uninstall.3
	deps/npm/man/man3/npm-unpublish.3
	deps/npm/man/man3/npm-update.3
	deps/npm/man/man3/npm-version.3
	deps/npm/man/man3/npm-view.3
	deps/npm/man/man3/npm-whoami.3
	deps/npm/man/man3/npm.3
	deps/npm/man/man5/npm-folders.5
	deps/npm/man/man5/npm-global.5
	deps/npm/man/man5/npm-json.5
	deps/npm/man/man7/npm-coding-style.7
	deps/npm/man/man7/npm-config.7
	deps/npm/man/man7/npm-developers.7
	deps/npm/man/man7/npm-disputes.7
	deps/npm/man/man7/npm-faq.7
	deps/npm/man/man7/npm-registry.7
	deps/npm/man/man7/npm-scripts.7
	deps/npm/man/man7/removing-npm.7
	deps/npm/man/man7/semver.7
	deps/npm/package.json
	deps/uv/AUTHORS
	deps/uv/ChangeLog
	deps/uv/src/version.c
	deps/uv/test/test-fs.c
	deps/uv/test/test-list.h
	lib/http.js
	lib/tls.js
	src/node_version.h
2013-07-12 13:26:56 -07:00
isaacs
831de7cbb9 http: Use OOP for OutgoingMessage._finish
Sniffing instanceof a child class in the parent class's method
is Doing It Wrong.
2013-07-09 22:31:11 -07:00
isaacs
49519f1217 http: Reuse more http/https Agent code 2013-07-09 22:31:11 -07:00
Trevor Norris
278183a902 {stream,udp,tls}_wrap: remove unused offset/length
The function arguments offset and length are now no longer used since
all I/O requests now use discretely allocated memory.
2013-07-03 15:03:41 -07:00
isaacs
adf9b67e59 Merge remote-tracking branch 'ry/v0.10' into master
Conflicts:
	ChangeLog
	deps/uv/ChangeLog
	deps/uv/src/unix/stream.c
	deps/uv/src/version.c
	deps/v8/build/common.gypi
	deps/v8/src/frames.h
	deps/v8/src/runtime.cc
	deps/v8/test/mjsunit/debug-set-variable-value.js
	lib/http.js
	src/node_version.h
2013-06-25 11:12:33 -07:00
Fedor Indutny
dc50f27d52 tls: share socket._hadError with http_client 2013-06-16 09:30:15 +02:00
isaacs
ba048e72b0 Merge remote-tracking branch 'ry/v0.10'
Conflicts:
	AUTHORS
	ChangeLog
	configure
	deps/uv/ChangeLog
	deps/uv/src/unix/darwin.c
	deps/uv/src/unix/stream.c
	deps/uv/src/version.c
	deps/v8/src/isolate.cc
	deps/v8/src/version.cc
	lib/http.js
	src/node_version.h
2013-05-27 14:46:52 -07:00
isaacs
896b2aa707 util: Add debuglog, deprecate console lookalikes 2013-05-21 16:39:50 -07:00
Timothy J Fontaine
951e0b69fa http: split Client into _http_client.js 2013-04-17 00:08:28 +02:00