socket.io-stream
Advanced tools
Comparing version 0.5.1 to 0.5.2
@@ -77,3 +77,3 @@ var util = require('util') | ||
// We can not read from the socket if it's destroyed obviously ... | ||
if(this.destroyed) return; | ||
if (this.destroyed) return; | ||
@@ -123,3 +123,4 @@ if (this.pushBuffer.length) { | ||
// We can not write to the socket if it's destroyed obviously ... | ||
if(self.destroyed) return; | ||
if (self.destroyed) return; | ||
self._writable = false; | ||
@@ -199,3 +200,6 @@ self.socket._write(self.id, chunk, encoding, callback); | ||
// send 'end' event to remote | ||
this.socket._end(this.id); | ||
if (this.socket) { | ||
this.socket._end(this.id); | ||
} | ||
this.writable = false; | ||
@@ -212,4 +216,8 @@ this._writableState.ended = true; | ||
if (!this.allowHalfOpen) { | ||
this.read(0); | ||
this.push(null); | ||
// just in case we're waiting for an EOF. | ||
if (this.readable && !this._readableState.endEmitted) { | ||
this.read(0); | ||
} | ||
} | ||
@@ -228,2 +236,3 @@ }; | ||
this.readable = false; | ||
this._readableState.ended = true; | ||
@@ -230,0 +239,0 @@ if (!this.writable || this._writableState.finished) { |
{ | ||
"name": "socket.io-stream", | ||
"version": "0.5.1", | ||
"version": "0.5.2", | ||
"description": "stream for socket.io", | ||
@@ -24,6 +24,7 @@ "author": "Naoyuki Kanezawa <naoyuki.kanezawa@gmail.com>", | ||
"scripts": { | ||
"test": "make test-all" | ||
"test": "make test-all", | ||
"prepublish": "make test-all build" | ||
}, | ||
"dependencies": { | ||
"readable-stream": "1.0.2", | ||
"readable-stream": "1.1.9", | ||
"debug": "*" | ||
@@ -38,3 +39,3 @@ }, | ||
"checksum": "*", | ||
"browserify": "*", | ||
"browserify": "2.36.1", | ||
"uglify-js": "*", | ||
@@ -41,0 +42,0 @@ "phantomjs": "*", |
Sorry, the diff of this file is too big to display
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Uses eval
Supply chain riskPackage uses dynamic code execution (e.g., eval()), which is a dangerous practice. This can prevent the code from running in certain environments and increases the risk that the code may contain exploits or malicious behavior.
Found 1 instance in 1 package
167165
1032
6
0
+ Addedcore-util-is@1.0.3(transitive)
+ Addeddebuglog@0.0.2(transitive)
+ Addedreadable-stream@1.1.9(transitive)
- Removedreadable-stream@1.0.2(transitive)
Updatedreadable-stream@1.1.9