Skip to content

Commit a0423c9

Browse files
committed
Fix set verdict data type unmarshalling
Currently unmarshalling sets with "verdict" data type results in the "verdict" type to be set as the key type, and the data type remaining zero. Properly set the verdict type to Set DataType field instead of the KeyType. Signed-off-by: Mikhail Sennikovsky <mikhail.sennikovskii@ionos.com>
1 parent 51c44dc commit a0423c9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

set.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -743,7 +743,7 @@ func setsFromMsg(msg netlink.Message) (*Set, error) {
743743
nftMagic := ad.Uint32()
744744
// Special case for the data type verdict, in the message it is stored as 0xffffff00 but it is defined as 1
745745
if nftMagic == 0xffffff00 {
746-
set.KeyType = TypeVerdict
746+
set.DataType = TypeVerdict
747747
break
748748
}
749749
dt, err := parseSetDatatype(nftMagic)

0 commit comments

Comments
 (0)