Fixed Error return value of is not checked (errcheck)

This commit is contained in:
Holger Obermaier
2026-02-06 14:13:05 +01:00
parent 2b5bf4d6a5
commit baf7a4f2c5

View File

@@ -1323,7 +1323,9 @@ func (m *NvidiaCollector) Read(interval time.Duration, output chan lp.CCMessage)
func (m *NvidiaCollector) Close() {
if m.init {
nvml.Shutdown()
if ret := nvml.Shutdown(); ret != nvml.SUCCESS {
cclog.ComponentError(m.name, "nvml.Shutdown() not successful")
}
m.init = false
}
}