mirror of
https://github.com/xcat2/xcat-core.git
synced 2026-09-21 16:39:30 +00:00
fix(networks): exclude every link-local address from the networks table
donets() only skips the exact address 'fe80::/64' when scanning routes, so a
link-local route with any other prefix (e.g. a longer fe80:: subnet) is added
to the networks table as a bogus network. Match any fe80:: prefix instead of
the single literal value.
Recovered from the unmerged lenovobuild branch (original 8b79cf85).
Co-authored-by: Jarrod Johnson <10814490+jjohnson42@users.noreply.github.com>
This commit is contained in:
@@ -388,7 +388,7 @@ sub donets
|
||||
foreach (@ip6table)
|
||||
{
|
||||
my @ent = split /\s+/, $_;
|
||||
if ($ent[0] eq 'fe80::/64' or $ent[0] eq 'unreachable' or
|
||||
if ($ent[0] =~ m/^fe80::/ or $ent[0] eq 'unreachable' or
|
||||
$ent[1] eq 'via' or $ent[2] eq 'lo') {
|
||||
|
||||
#Do not contemplate link-local, unreachable, gatewayed networks,
|
||||
|
||||
Reference in New Issue
Block a user