Merge pull request #2527 from nzalev/fix-logtxt-permission-bits

Fixed log.txt permission bits
This commit is contained in:
Ylian Saint-Hilaire 2021-04-19 20:29:26 -07:00 committed by GitHub
commit 7e692a2cc5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -2844,7 +2844,7 @@ function CreateMeshCentralServer(config, args) {
const d = new Date();
if (obj.xxLogFile == null) {
try {
obj.xxLogFile = obj.fs.openSync(obj.getConfigFilePath('log.txt'), 'a+', 666);
obj.xxLogFile = obj.fs.openSync(obj.getConfigFilePath('log.txt'), 'a+', 0o666);
obj.fs.writeSync(obj.xxLogFile, '---- Log start at ' + new Date().toLocaleString() + ' ----\r\n');
obj.xxLogDateStr = d.toLocaleDateString();
} catch (ex) { }