mirror of
https://github.com/manuelkasper/AS-Stats.git
synced 2025-02-20 11:44:12 +08:00
Fix for multiple entries with the same tag in the
knownlinks file (e.g. for LACP).
This commit is contained in:
parent
2f3e135afa
commit
944c0909ad
@ -146,7 +146,13 @@ sub read_knownlinks {
|
||||
next if (/(^\s*#)|(^\s*$)/); # empty line or comment
|
||||
|
||||
my ($routerip,$ifindex,$tag,$descr,$color) = split(/\t+/);
|
||||
$knownlinks{"${routerip}_${ifindex}"} = $tag;
|
||||
my $known = 0;
|
||||
foreach my $link (values %knownlinks) {
|
||||
if ($tag =~ $link) { $known=1; last; }
|
||||
}
|
||||
if ($known == 0) {
|
||||
$knownlinks{"${routerip}_${ifindex}"} = $tag;
|
||||
}
|
||||
}
|
||||
close(KLFILE);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user