|
@@ -1905,7 +1905,7 @@ static int nf_tables_fill_rule_info(struct sk_buff *skb, struct net *net,
|
|
|
goto nla_put_failure;
|
|
|
|
|
|
if ((event != NFT_MSG_DELRULE) && (rule->list.prev != &chain->rules)) {
|
|
|
- prule = list_entry(rule->list.prev, struct nft_rule, list);
|
|
|
+ prule = list_prev_entry(rule, list);
|
|
|
if (nla_put_be64(skb, NFTA_RULE_POSITION,
|
|
|
cpu_to_be64(prule->handle),
|
|
|
NFTA_RULE_PAD))
|