Skip to content

Commit 33e20b8

Browse files
committed
[bridgeconfig] AI suggested fixes.
store Advertised values to the copy and not to the original object. isIPv6 should be true in ipv6 case. Signed-off-by: Nadia Pinaeva <[email protected]>
1 parent f531e3d commit 33e20b8

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

go-controller/pkg/node/bridgeconfig/bridgeconfig.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ func (netConfig *BridgeUDNConfiguration) ShallowCopy() *BridgeUDNConfiguration {
4444
Subnets: netConfig.Subnets,
4545
NodeSubnets: netConfig.NodeSubnets,
4646
}
47-
netConfig.Advertised.Store(netConfig.Advertised.Load())
47+
copy.Advertised.Store(netConfig.Advertised.Load())
4848
return copy
4949
}
5050

go-controller/pkg/node/bridgeconfig/bridgeconfig_testutil.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ func CheckAdvertisedUDNSvcIsolationOVSFlows(flows []string, netConfig *BridgeUDN
8080
Expect(err).ToNot(HaveOccurred())
8181
protoPrefix = "ip"
8282
} else {
83-
matchingIPFamilySubnet, err = util.MatchFirstIPNetFamily(false, udnAdvertisedSubnets)
83+
matchingIPFamilySubnet, err = util.MatchFirstIPNetFamily(true, udnAdvertisedSubnets)
8484
Expect(err).ToNot(HaveOccurred())
8585
protoPrefix = "ip6"
8686
}

0 commit comments

Comments
 (0)