Fix Use of uninitialized value in substr at /usr/share/perl5/SNMP/Info/IPv6.pm line 113. It is caused by an empty mac in local loopback interface on cisco devices.
Signed-off-by: Jeroen van Ingen <jeroen@utwente.nl>
This commit is contained in:
committed by
Jeroen van Ingen
parent
8199e2a973
commit
c9a36f12e6
@@ -108,7 +108,7 @@ sub ipv6_n2p_mac {
|
||||
$v6addr = join('.', $addrtype, $addrsize, $v6addr);
|
||||
$addrtype = 2;
|
||||
}
|
||||
if ($addrtype == 2) { # IPv6
|
||||
if (($addrtype == 2) && (defined $phys_addr->{$row})) { # IPv6
|
||||
$return->{$row} = substr($phys_addr->{$row}, 0, 17);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user