From: Florian Forster Date: Tue, 26 Aug 2008 15:58:28 +0000 (+0200) Subject: contrib/snmp-probe-host.px: Work-around for Windows systems. X-Git-Tag: collectd-4.3.4~4 X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=e6c7276f2e1294601f35d8ff852f6e4cd345f2f2;p=collectd.git contrib/snmp-probe-host.px: Work-around for Windows systems. They don't return an error, but `success' and a string stating NOSUCHOBJECT. Just great. --- diff --git a/contrib/snmp-probe-host.px b/contrib/snmp-probe-host.px index 9130ecec..1cfaa072 100755 --- a/contrib/snmp-probe-host.px +++ b/contrib/snmp-probe-host.px @@ -99,6 +99,14 @@ sub probe_one { return; } + if (!defined ($status)) + { + return; + } + if ("$status" eq 'NOSUCHOBJECT') + { + return; + } } else {