Fix for #2498
Ylian Saint-Hilaire committed
Apr 9, 2021 at 15:00 UTC
c6e1a44581285ce3e8ddfcfd89b766d81fccead3
1 file changed
+1
-1
amt/amt-wsman-comm.js
+1
-1
@@ -76,7 +76,7 @@ var CreateWsmanComm = function (host, port, user, pass, tls, tlsoptions, mpsConn
76
function SerialTunnel(options) {
77
var obj = new require('stream').Duplex(options);
78
obj.forwardwrite = null;
79
- obj.updateBuffer = function (chunk) { this.push(chunk); };
79
+ obj.updateBuffer = function (chunk) { try { this.push(chunk); } catch (ex) { } };
80
obj._write = function (chunk, encoding, callback) { if (obj.forwardwrite != null) { obj.forwardwrite(chunk); } else { console.err("Failed to fwd _write."); } if (callback) callback(); }; // Pass data written to forward
81
obj._read = function (size) { }; // Push nothing, anything to read should be pushed from updateBuffer()
82
return obj;