]> git.ipfire.org Git - thirdparty/iptables.git/commitdiff
xtables: Free chains in NFT_COMPAT_CHAIN_USER_DEL jobs
authorPhil Sutter <phil@nwl.cc>
Thu, 2 Aug 2018 15:05:10 +0000 (17:05 +0200)
committerFlorian Westphal <fw@strlen.de>
Sat, 4 Aug 2018 12:12:44 +0000 (14:12 +0200)
These always have to be freed because nft_chain_user_del() removes them
from the cache so they are not freed when the chain cache is flushed.

Signed-off-by: Phil Sutter <phil@nwl.cc>
Signed-off-by: Florian Westphal <fw@strlen.de>
iptables/nft.c

index f2d6ea137e48d3b160959e82c5141912c79400e5..26df1287c518843db110481657937a47f69328f6 100644 (file)
@@ -2447,8 +2447,8 @@ static void batch_obj_del(struct nft_handle *h, struct obj_update *o)
                break;
        case NFT_COMPAT_CHAIN_ADD:
        case NFT_COMPAT_CHAIN_USER_ADD:
-       case NFT_COMPAT_CHAIN_USER_DEL:
                break;
+       case NFT_COMPAT_CHAIN_USER_DEL:
        case NFT_COMPAT_CHAIN_USER_FLUSH:
        case NFT_COMPAT_CHAIN_UPDATE:
        case NFT_COMPAT_CHAIN_RENAME: