mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-09-29 22:02:02 +00:00
netfilter: nf_tables: Drop pointless memset when dumping rules
[ Upstream commit30fa41a0f6
] None of the dump callbacks uses netlink_callback::args beyond the first element, no need to zero the data. Fixes:96518518cc
("netfilter: add nftables") Signed-off-by: Phil Sutter <phil@nwl.cc> Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
parent
80986257d2
commit
bfd4ed4988
1 changed files with 0 additions and 4 deletions
|
@ -3184,10 +3184,6 @@ static int __nf_tables_dump_rules(struct sk_buff *skb,
|
||||||
goto cont_skip;
|
goto cont_skip;
|
||||||
if (*idx < s_idx)
|
if (*idx < s_idx)
|
||||||
goto cont;
|
goto cont;
|
||||||
if (*idx > s_idx) {
|
|
||||||
memset(&cb->args[1], 0,
|
|
||||||
sizeof(cb->args) - sizeof(cb->args[0]));
|
|
||||||
}
|
|
||||||
if (prule)
|
if (prule)
|
||||||
handle = prule->handle;
|
handle = prule->handle;
|
||||||
else
|
else
|
||||||
|
|
Loading…
Reference in a new issue