1
0
mirror of https://github.com/opinkerfi/nagios-plugins.git synced 2024-11-22 10:23:46 +01:00

check_snmp_interfaces - empty interfaces make plugin broken, do they that they are.

This commit is contained in:
Tómas Edwardsson 2010-03-16 17:02:58 +00:00
parent b9ada8f469
commit 871a4ee631

View File

@ -230,6 +230,10 @@ foreach my $key ( keys %$resultat) {
#$index = 1; #$index = 1;
#while ( $index <= $number_of_interfaces ) { #while ( $index <= $number_of_interfaces ) {
# Weed out empty entries
@keys = grep(!/^$/, @keys);
foreach $index ( @keys ) { foreach $index ( @keys ) {
my $target_interface_index = $index; my $target_interface_index = $index;
$oid_temp = $oid_ifdescr . $index; $oid_temp = $oid_ifdescr . $index;