Skip to content

Commit

Permalink
netfilter: nf_tables: selective rule dump needs table to be specified
Browse files Browse the repository at this point in the history
Table needs to be specified for selective rule dumps per chain.

Fixes: 241faec ("netfilter: nf_tables: Speed up selective rule dumps")
Reported-by: Florian Westphal <fw@strlen.de>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
  • Loading branch information
Pablo Neira Ayuso committed Jan 8, 2019
1 parent b91d903 commit 715849a
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 @@ -2350,7 +2350,7 @@ static int nf_tables_dump_rules(struct sk_buff *skb,
if (ctx && ctx->table && strcmp(ctx->table, table->name) != 0)
continue;

if (ctx && ctx->chain) {
if (ctx && ctx->table && ctx->chain) {
struct rhlist_head *list, *tmp;

list = rhltable_lookup(&table->chains_ht, ctx->chain,
Expand Down

0 comments on commit 715849a

Please sign in to comment.