Skip to content

Commit

Permalink
fix network policy err
Browse files Browse the repository at this point in the history
  • Loading branch information
gugulee committed May 5, 2023
1 parent d6fb4a3 commit 20fb321
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion pkg/ovs/ovn-nb-address_set.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,11 @@ package ovs
import (
"context"
"fmt"
"net"
"strings"

"github.com/ovn-org/libovsdb/client"
"k8s.io/klog/v2"

"github.com/kubeovn/kube-ovn/pkg/ovsdb/ovnnb"
"github.com/kubeovn/kube-ovn/pkg/util"
Expand Down Expand Up @@ -55,7 +58,7 @@ func (c *ovnClient) AddressSetUpdateAddress(asName string, addresses ...string)
// update will failed when slice contains duplicate elements
addresses = util.UniqString(addresses)

// format CIDR to keep addresses the same in both nb and sb
// format CIDR to keep addresses the same in both nb and sb
for i, addr := range addresses {
if strings.ContainsRune(addr, '/') {
_, ipNet, err := net.ParseCIDR(addr)
Expand Down

0 comments on commit 20fb321

Please sign in to comment.