Skip to content

Commit f6d0bc4

Browse files
committed
hardware monitor fixed load offset on unix devices
1 parent 17ec7ae commit f6d0bc4

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

hardware/HardwareMonitor.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -584,7 +584,7 @@ void CHardwareMonitor::RunWMIQuery(const char* qTable,const char* qType)
584584
if (cpuper>0)
585585
{
586586
sprintf(szTmp,"%.2f", cpuper);
587-
UpdateSystemSensor("Load", 0, "CPU_Usage", "CPU_Usage", szTmp);
587+
UpdateSystemSensor("Load", 1, "CPU_Usage", "CPU_Usage", szTmp);
588588
}
589589
m_lastloadcpu=actload1+actload2+actload3;
590590
}
@@ -626,7 +626,7 @@ void CHardwareMonitor::RunWMIQuery(const char* qTable,const char* qType)
626626
double UsagedPercentage=(100 / double(dusage.TotalBlocks))*double(dusage.UsedBlocks);
627627
//std::cout << "Disk: " << (*ittDisks).first << ", Mount: " << dusage.MountPoint << ", Used: " << UsagedPercentage << std::endl;
628628
sprintf(szTmp,"%.2f", UsagedPercentage);
629-
UpdateSystemSensor("Load", dindex, (*ittDisks).first, dusage.MountPoint, szTmp);
629+
UpdateSystemSensor("Load", 2+dindex, (*ittDisks).first, dusage.MountPoint, szTmp);
630630
dindex++;
631631
}
632632
}

0 commit comments

Comments
 (0)