Module: check_mk
Branch: master
Commit: 2a1f95c254f66e0c3c5fcce0ea23927e38566e1c
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=2a1f95c254f66e…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Thu Aug 25 14:47:14 2016 +0200
3769 FIX cisco_temperature: Fixed exception in case of empty SNMP data received from
device
---
.werks/3769 | 10 ++++++++++
ChangeLog | 1 +
checks/cisco_temperature | 2 +-
3 files changed, 12 insertions(+), 1 deletion(-)
diff --git a/.werks/3769 b/.werks/3769
new file mode 100644
index 0000000..5412a86
--- /dev/null
+++ b/.werks/3769
@@ -0,0 +1,10 @@
+Title: cisco_temperature: Fixed exception in case of empty SNMP data received from
device
+Level: 1
+Component: checks
+Class: fix
+Compatible: compat
+State: unknown
+Version: 1.4.0i1
+Date: 1472129201
+
+
diff --git a/ChangeLog b/ChangeLog
index 07ddcfe..4a5cb53 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -354,6 +354,7 @@
* 3764 FIX: netapp_api_vs_traffic: Fixed exception when no NFSv4 infos available
* 3765 FIX: oracle_asm_diskgroup: Made check more robust against invalid data
received from agent...
* 3766 FIX: palo_alto_sessions: Fixed possible division by zero error
+ * 3769 FIX: cisco_temperature: Fixed exception in case of empty SNMP data received
from device
Multisite:
* 3187 notification view: new filter for log command via regex
diff --git a/checks/cisco_temperature b/checks/cisco_temperature
index b17cbbd..e26b4b7 100644
--- a/checks/cisco_temperature
+++ b/checks/cisco_temperature
@@ -98,7 +98,7 @@ def parse_cisco_temperature(info):
entity_parsed[descr] = (3, "Data from sensor currently not
available")
elif sensorstate == '3':
entity_parsed[descr] = (3, "Sensor is broken")
- else:
+ elif sensorstate == '1':
entity_parsed[descr] = {}
scale = 10**int(magnitude)