Updated https support
This commit is contained in:
parent
144200435f
commit
fbad5dc062
@ -303,7 +303,8 @@ function initStream (self) {
|
|||||||
}
|
}
|
||||||
if (secureBytesRead === null && !self.server) {
|
if (secureBytesRead === null && !self.server) {
|
||||||
// Client needs to write as part of handshake
|
// Client needs to write as part of handshake
|
||||||
this._writeWatcher.start();
|
self._writeWatcher.start();
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
bytesRead = read(self.fd,
|
bytesRead = read(self.fd,
|
||||||
@ -312,7 +313,6 @@ function initStream (self) {
|
|||||||
pool.length - pool.used);
|
pool.length - pool.used);
|
||||||
}
|
}
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
if (this.forceClose) this.forceClose(e);
|
|
||||||
self.destroy(e);
|
self.destroy(e);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -523,7 +523,7 @@ Stream.prototype._writeOut = function (data, encoding) {
|
|||||||
if (this.secure) return false;
|
if (this.secure) return false;
|
||||||
else throw new Error('Stream is not writable');
|
else throw new Error('Stream is not writable');
|
||||||
}
|
}
|
||||||
if (data.length == 0) return true;
|
if (!this.secure && data.length == 0) return true;
|
||||||
|
|
||||||
var buffer, off, len;
|
var buffer, off, len;
|
||||||
var bytesWritten, charsWritten;
|
var bytesWritten, charsWritten;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user