mirror of
https://github.com/c-kr/check_json.git
synced 2026-02-05 22:55:15 +01:00
fixed threshold output in perfdata
This commit is contained in:
@@ -86,14 +86,16 @@ if (defined $np->opts->divisor) {
|
|||||||
$value = $value/$np->opts->divisor;
|
$value = $value/$np->opts->divisor;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
my $result = $np->check_threshold($value);
|
||||||
|
|
||||||
$np->add_perfdata(
|
$np->add_perfdata(
|
||||||
label => 'value',
|
label => 'value',
|
||||||
value => $value,
|
value => $value,
|
||||||
#threshold => $threshold,
|
threshold => $np->threshold(),
|
||||||
);
|
);
|
||||||
|
|
||||||
$np->nagios_exit(
|
$np->nagios_exit(
|
||||||
return_code => $np->check_threshold($value),
|
return_code => $result,
|
||||||
message => $value
|
message => $value,
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user