mirror of
https://github.com/Ylianst/MeshAgent
synced 2025-12-16 16:23:25 +00:00
Removed linux only restriction to getLibInfo()
This commit is contained in:
File diff suppressed because one or more lines are too long
@@ -36,8 +36,6 @@ var AnyPropertyType = 0;
|
|||||||
|
|
||||||
function getLibInfo(libname)
|
function getLibInfo(libname)
|
||||||
{
|
{
|
||||||
if (process.platform != 'linux') { throw ('Only supported on linux'); }
|
|
||||||
|
|
||||||
var child = require('child_process').execFile('/bin/sh', ['sh']);
|
var child = require('child_process').execFile('/bin/sh', ['sh']);
|
||||||
child.stdout.str = '';
|
child.stdout.str = '';
|
||||||
child.stdout.on('data', function (chunk) { this.str += chunk.toString(); });
|
child.stdout.on('data', function (chunk) { this.str += chunk.toString(); });
|
||||||
@@ -713,7 +711,7 @@ if (process.platform != 'darwin')
|
|||||||
module.exports = new monitorinfo();
|
module.exports = new monitorinfo();
|
||||||
}
|
}
|
||||||
|
|
||||||
if (process.platform == 'linux')
|
if (process.platform == 'linux' || process.platform == 'freebsd')
|
||||||
{
|
{
|
||||||
module.exports.getLibInfo = getLibInfo;
|
module.exports.getLibInfo = getLibInfo;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user