diff --git a/index.js b/index.js index 3387695..5d4b441 100644 --- a/index.js +++ b/index.js @@ -151,7 +151,7 @@ Mod.prototype.callback = function (req, res, serverconsole, responseEnd, href, e try { res.writeHead(code, msg, bheaderso); - res.write(buffer.substr(headerendline + eol.length), "latin1"); + res.write(Buffer.from(buffer.substr(headerendline + eol.length), "latin1")); } catch (ex) { socket.removeAllListeners("data"); socket.removeAllListeners("end"); diff --git a/mod.info b/mod.info index e270284..7c842c5 100755 --- a/mod.info +++ b/mod.info @@ -1,4 +1,4 @@ { "name": "OrangeCircle SCGI client for SVR.JS", - "version": "1.2.0" + "version": "1.2.1" }