Browse Source

http: use `self.keepAlive` instead of `self.options.keepAlive`

In http.agent, all other options are directly accessed through
`self.` not `self.options`.

PR-URL: https://github.com/nodejs/node/pull/4407
Reviewed-By: Brian White <mscdex@mscdex.net>
Reviewed-By: Fedor Indutny <fedor.indutny@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
v4.x
Damian Schenkelman 9 years ago
committed by Myles Borins
parent
commit
41fcda840c
  1. 2
      lib/_http_agent.js

2
lib/_http_agent.js

@ -58,7 +58,7 @@ function Agent(options) {
if (req &&
req.shouldKeepAlive &&
!socket.destroyed &&
self.options.keepAlive) {
self.keepAlive) {
var freeSockets = self.freeSockets[name];
var freeLen = freeSockets ? freeSockets.length : 0;
var count = freeLen;

Loading…
Cancel
Save