mirror of
https://github.com/centreon/centreon-plugins.git
synced 2025-07-26 23:24:27 +02:00
(plugin) network::fiberstore::snmp - harden memory mode check (#3514)
This commit is contained in:
parent
91b5064fe3
commit
a226363e2c
@ -100,6 +100,11 @@ sub manage_selection {
|
|||||||
if (!defined($result->{total})) {
|
if (!defined($result->{total})) {
|
||||||
($total, $free) = ('total_legacy', 'free_legacy');
|
($total, $free) = ('total_legacy', 'free_legacy');
|
||||||
}
|
}
|
||||||
|
if ($result->{$total} !~ /[0-9]+/) {
|
||||||
|
$self->{output}->add_option_msg(short_msg => 'cannot get informations');
|
||||||
|
$self->{output}->option_exit();
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
$result->{$total} *= 1024;
|
$result->{$total} *= 1024;
|
||||||
$result->{$free} *= 1024;
|
$result->{$free} *= 1024;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user