system() added uuid freebsd

This commit is contained in:
Sebastian Hildebrandt 2025-06-19 11:17:45 +02:00
parent ef5286e6cc
commit d4f53d947c

View File

@ -124,7 +124,7 @@ function system(callback) {
try {
const lines = execSync('sysctl -i kern.hostuuid kern.hostid', util.execOptsLinux).toString().split('\n');
result.uuid = util.getValue(lines, 'kern.hostuuid', ':').toLowerCase();
if (!result.serial) {
if (!result.serial || result.serial === '-') {
result.serial = util.getValue(lines, 'kern.hostid', ':').toLowerCase();
}
} catch (e) {