diff options
Diffstat (limited to 'net/netfilter/nft_objref.c')
| -rw-r--r-- | net/netfilter/nft_objref.c | 14 | 
1 files changed, 4 insertions, 10 deletions
| diff --git a/net/netfilter/nft_objref.c b/net/netfilter/nft_objref.c index 1ae8c49ca4a1..1dd428fbaaa3 100644 --- a/net/netfilter/nft_objref.c +++ b/net/netfilter/nft_objref.c @@ -116,16 +116,10 @@ static int nft_objref_map_init(const struct nft_ctx *ctx,  	struct nft_set *set;  	int err; -	set = nf_tables_set_lookup(ctx->table, tb[NFTA_OBJREF_SET_NAME], genmask); -	if (IS_ERR(set)) { -		if (tb[NFTA_OBJREF_SET_ID]) { -			set = nf_tables_set_lookup_byid(ctx->net, -							tb[NFTA_OBJREF_SET_ID], -							genmask); -		} -		if (IS_ERR(set)) -			return PTR_ERR(set); -	} +	set = nft_set_lookup(ctx->net, ctx->table, tb[NFTA_OBJREF_SET_NAME], +			     tb[NFTA_OBJREF_SET_ID], genmask); +	if (IS_ERR(set)) +		return PTR_ERR(set);  	if (!(set->flags & NFT_SET_OBJECT))  		return -EINVAL; | 
