diff --git a/lib/node-static.js b/lib/node-static.js index 040f0aa..80a4882 100644 --- a/lib/node-static.js +++ b/lib/node-static.js @@ -366,7 +366,7 @@ Server.prototype.stream = function (pathname, files, buffer, startByte, res, cal // Stream the file to the client fs.createReadStream(file, { flags: 'r', - mode: 0666, + mode: parseInt('0666',8), start: startByte, end: startByte + (buffer.length ? buffer.length - 1 : 0) }).on('data', function (chunk) {