Browse Source

Connection: use socket.end() instead of socket.destroy()

fork
Brian White 7 years ago
parent
commit
1745b22f25
  1. 4
      lib/Connection.js

4
lib/Connection.js

@ -292,7 +292,7 @@ Connection.prototype.serverSupports = function(cap) {
Connection.prototype.destroy = function() {
this._queue = [];
this._curReq = undefined;
this._sock && this._sock.destroy();
this._sock && this._sock.end();
};
Connection.prototype.end = function() {
@ -1591,7 +1591,7 @@ Connection.prototype._login = function() {
clearTimeout(self._tmrAuth);
if (err) {
self.emit('error', err);
return self._sock.destroy();
return self._sock.end();
}
// 2. Get the list of available namespaces (RFC2342)

Loading…
Cancel
Save