summaryrefslogtreecommitdiffstats
path: root/lib/Nagios/Plugin/Threshold.pm
diff options
context:
space:
mode:
authorTon Voon <tonvoon@users.sourceforge.net>2007-08-31 13:21:10 +0000
committerTon Voon <tonvoon@users.sourceforge.net>2007-08-31 13:21:10 +0000
commit95dba9c4213c2e7e8f4b572efd873c1979406221 (patch)
treec39a8dc0022ae98b09bfe5fa75f2dc67b3c97a69 /lib/Nagios/Plugin/Threshold.pm
parent4421aa3c2a695335cad006f32ece6c9c5da11165 (diff)
downloadmonitoring-plugin-perl-95dba9c4213c2e7e8f4b572efd873c1979406221.tar.gz
Fixed bug where warn or crit = 0 will raise an error. Optional flag to
tell nagios_die to use die instead of exit so trappable by eval git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/Nagios-Plugin/trunk@1772 f882894a-f735-0410-b71e-b25c423dba1c
Diffstat (limited to 'lib/Nagios/Plugin/Threshold.pm')
-rw-r--r--lib/Nagios/Plugin/Threshold.pm4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/Nagios/Plugin/Threshold.pm b/lib/Nagios/Plugin/Threshold.pm
index ad58134..145b89f 100644
--- a/lib/Nagios/Plugin/Threshold.pm
+++ b/lib/Nagios/Plugin/Threshold.pm
@@ -40,8 +40,8 @@ sub _inflate
40 } 40 }
41 41
42 # Otherwise parse $value 42 # Otherwise parse $value
43 my $range = Nagios::Plugin::Range->parse_range_string($value) 43 my $range = Nagios::Plugin::Range->parse_range_string($value);
44 or nagios_die("Cannot parse $key range: '$value'"); 44 nagios_die("Cannot parse $key range: '$value'") unless(defined($range));
45 return $range; 45 return $range;
46} 46}
47 47