mirror of
https://github.com/edk2-porting/linux-next.git
synced 2024-12-15 08:44:14 +08:00
netfilter: nf_tables_trace: fix endiness when dump chain policy
NFTA_TRACE_POLICY attribute is big endian, but we forget to call htonl to convert it. Fortunately, this attribute is parsed as big endian in libnftnl. Signed-off-by: Liping Zhang <liping.zhang@spreadtrum.com> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
This commit is contained in:
parent
6e1ce3c345
commit
5210d393ef
@ -237,7 +237,7 @@ void nft_trace_notify(struct nft_traceinfo *info)
|
||||
break;
|
||||
case NFT_TRACETYPE_POLICY:
|
||||
if (nla_put_be32(skb, NFTA_TRACE_POLICY,
|
||||
info->basechain->policy))
|
||||
htonl(info->basechain->policy)))
|
||||
goto nla_put_failure;
|
||||
break;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user