Fixed empty value maps error
This commit is contained in:
parent
10f682b497
commit
b390b827cb
1 changed files with 2 additions and 2 deletions
|
|
@ -759,7 +759,7 @@ SNMP::initMib();
|
||||||
|
|
||||||
# Verify the specified OID exists
|
# Verify the specified OID exists
|
||||||
if ($opts->{ oid } !~ m/^\./) {
|
if ($opts->{ oid } !~ m/^\./) {
|
||||||
$opts->{ oid } = "." . $opts->{ oid }
|
$opts->{ oid } = "." . $opts->{ oid }
|
||||||
}
|
}
|
||||||
|
|
||||||
my $oid_root = $SNMP::MIB{ $opts->{ oid } };
|
my $oid_root = $SNMP::MIB{ $opts->{ oid } };
|
||||||
|
|
@ -842,7 +842,7 @@ if (!$oid_root || $oid_root->{ objectID } ne $opts->{ oid }) {
|
||||||
'trigger_prototypes' => 'trigger_prototype',
|
'trigger_prototypes' => 'trigger_prototype',
|
||||||
'graph_prototypes' => 'graph_prototype',
|
'graph_prototypes' => 'graph_prototype',
|
||||||
'host_prototypes' => 'host_prototype',
|
'host_prototypes' => 'host_prototype',
|
||||||
'value_maps' => 'value_map',
|
'value_maps' => %{ $valuemaps } ? 'value_map' : undef,
|
||||||
'mappings' => 'mapping'
|
'mappings' => 'mapping'
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue