1
0
mirror of https://github.com/Ylianst/MeshAgent synced 2025-12-16 00:03:45 +00:00

Removed linux only restriction to getLibInfo()

This commit is contained in:
Bryan Roe
2021-01-28 23:24:59 -08:00
parent 3918aff513
commit a848bc6da8
2 changed files with 2 additions and 4 deletions

File diff suppressed because one or more lines are too long

View File

@@ -36,8 +36,6 @@ var AnyPropertyType = 0;
function getLibInfo(libname)
{
if (process.platform != 'linux') { throw ('Only supported on linux'); }
var child = require('child_process').execFile('/bin/sh', ['sh']);
child.stdout.str = '';
child.stdout.on('data', function (chunk) { this.str += chunk.toString(); });
@@ -713,7 +711,7 @@ if (process.platform != 'darwin')
module.exports = new monitorinfo();
}
if (process.platform == 'linux')
if (process.platform == 'linux' || process.platform == 'freebsd')
{
module.exports.getLibInfo = getLibInfo;
}