Fix sensor read error stops reporting of all sensors in temp input (#5941)
This commit is contained in:
committed by
Daniel Nelson
parent
d260437318
commit
4b6e791908
@@ -171,7 +171,14 @@ func (s *SystemPS) SwapStat() (*mem.SwapMemoryStat, error) {
|
||||
}
|
||||
|
||||
func (s *SystemPS) Temperature() ([]host.TemperatureStat, error) {
|
||||
return host.SensorsTemperatures()
|
||||
temp, err := host.SensorsTemperatures()
|
||||
if err != nil {
|
||||
_, ok := err.(*host.Warnings)
|
||||
if !ok {
|
||||
return temp, err
|
||||
}
|
||||
}
|
||||
return temp, nil
|
||||
}
|
||||
|
||||
func (s *SystemPSDisk) Partitions(all bool) ([]disk.PartitionStat, error) {
|
||||
|
||||
Reference in New Issue
Block a user