Skip to content

Commit

Permalink
netfilter: nf_tables: fix wrong check of NFT_SET_MAP in nf_tables_bin…
Browse files Browse the repository at this point in the history
…d_set

We should check "i" is used as a dictionary or not, "binding" is already
checked before.

Signed-off-by: Liping Zhang <liping.zhang@spreadtrum.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
  • Loading branch information
Liping Zhang authored and Pablo Neira Ayuso committed Jun 15, 2016
1 parent 7757114 commit a468440
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion net/netfilter/nf_tables_api.c
Original file line number Diff line number Diff line change
Expand Up @@ -2946,7 +2946,7 @@ int nf_tables_bind_set(const struct nft_ctx *ctx, struct nft_set *set,
* jumps are already validated for that chain.
*/
list_for_each_entry(i, &set->bindings, list) {
if (binding->flags & NFT_SET_MAP &&
if (i->flags & NFT_SET_MAP &&
i->chain == binding->chain)
goto bind;
}
Expand Down

0 comments on commit a468440

Please sign in to comment.