Fix: remove not pr-related changes

This commit is contained in:
ignatella 2024-11-04 18:08:39 +01:00
parent afa496e5e9
commit a77a91fb46
1 changed files with 1 additions and 3 deletions

4
set.go
View File

@ -800,8 +800,7 @@ func elementsFromMsg(fam byte, msg netlink.Message) ([]SetElement, error) {
var elements []SetElement var elements []SetElement
for ad.Next() { for ad.Next() {
b := ad.Bytes() b := ad.Bytes()
switch ad.Type() { if ad.Type() == unix.NFTA_SET_ELEM_LIST_ELEMENTS {
case unix.NFTA_SET_ELEM_LIST_ELEMENTS:
ad, err := netlink.NewAttributeDecoder(b) ad, err := netlink.NewAttributeDecoder(b)
if err != nil { if err != nil {
return nil, err return nil, err
@ -818,7 +817,6 @@ func elementsFromMsg(fam byte, msg netlink.Message) ([]SetElement, error) {
} }
} }
} }
return elements, nil return elements, nil
} }