Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

agentkeepalive

Package Overview
Dependencies
Maintainers
1
Versions
49
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

agentkeepalive - npm Package Compare versions

Comparing version 0.2.2 to 0.2.3

6

History.md
0.2.3 / 2014-10-16
==================
* added isDestroyed function to check _destroyed as well (@retool)
* fix https test
0.2.2 / 2013-11-19

@@ -3,0 +9,0 @@ ==================

11

lib/_http_agent.js

@@ -79,3 +79,3 @@ // Copyright Joyent, Inc. and other Node contributors.

if (!socket.destroyed &&
if (!self.isDestroyed(socket) &&
self.requests[name] && self.requests[name].length) {

@@ -93,3 +93,3 @@ self.requests[name].shift().onSocket(socket);

req.shouldKeepAlive &&
!socket.destroyed &&
!self.isDestroyed(socket) &&
self.options.keepAlive) {

@@ -245,5 +245,5 @@ var freeSockets = self.freeSockets[name];

var name = this.getName(options);
debug('removeSocket', name, 'destroyed:', s.destroyed);
debug('removeSocket', name, 'destroyed:', this.isDestroyed(s));
var sets = [this.sockets];
if (s.destroyed) {
if (this.isDestroyed(s)) {
// If the socket was destroyed, we need to remove it from the free buffers.

@@ -326,2 +326,5 @@ sets.push(this.freeSockets);

Agent.prototype.isDestroyed = function(socket){
return socket.destroyed || socket._destroyed;
}
exports.globalAgent = new Agent();

@@ -63,3 +63,3 @@ /**!

if (!socket.destroyed &&
if (!self.isDestroyed(socket) &&
self.requests[name] && self.requests[name].length) {

@@ -77,3 +77,3 @@ self.requests[name].shift().onSocket(socket);

req.shouldKeepAlive &&
!socket.destroyed &&
!self.isDestroyed(socket) &&
self.options.keepAlive) {

@@ -144,5 +144,5 @@ var freeSockets = self.freeSockets[name];

var name = this.getName(options);
debug('removeSocket', name, 'destroyed:', s.destroyed);
debug('removeSocket', name, 'destroyed:', this.isDestroyed(s));
if (s.destroyed && this.freeSockets[name]) {
if (this.isDestroyed(s) && this.freeSockets[name]) {
var index = this.freeSockets[name].indexOf(s);

@@ -149,0 +149,0 @@ if (index !== -1) {

{
"name": "agentkeepalive",
"version": "0.2.2",
"version": "0.2.3",
"description": "Missing keepalive http.Agent",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -1,7 +0,3 @@

# agentkeepalive
# agentkeepalive [![Build Status](https://secure.travis-ci.org/TBEDP/agentkeepalive.png?branch=master)](http://travis-ci.org/TBEDP/agentkeepalive) [![Coverage Status](https://coveralls.io/repos/TBEDP/agentkeepalive/badge.png)](https://coveralls.io/r/TBEDP/agentkeepalive)
[![Build Status](https://secure.travis-ci.org/TBEDP/agentkeepalive.png?branch=master)](http://travis-ci.org/TBEDP/agentkeepalive) [![Coverage Status](https://coveralls.io/repos/TBEDP/agentkeepalive/badge.png)](https://coveralls.io/r/TBEDP/agentkeepalive)
[![NPM](https://nodei.co/npm/agentkeepalive.png?downloads=true)](https://nodei.co/npm/agentkeepalive/)
![logo](https://raw.github.com/TBEDP/agentkeepalive/master/logo.png)

@@ -8,0 +4,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc