mirror of
https://github.com/Spearfoot/FreeNAS-scripts
synced 2025-12-06 01:23:19 +00:00
Use numeric values for CPU temperature (#23)
Fixes Spearfoot/FreeNAS-scripts#20 and Spearfoot/FreeNAS-scripts#21
This commit is contained in:
@@ -148,6 +148,7 @@ sub display_cpu_temps
|
||||
for (my $core=0; $core < $cpucores; $core++)
|
||||
{
|
||||
$temp = qx(sysctl -n dev.cpu.$core.temperature);
|
||||
$temp =~ s/[^\-[:digit:]\.]//g;
|
||||
chomp($temp);
|
||||
if ($temp <= 0)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user