]> git.baikalelectronics.ru Git - kernel.git/commit
netfilter: nf_tables: do not leave chain stats enabled on error
authorPablo Neira Ayuso <pablo@netfilter.org>
Sun, 21 Aug 2022 10:41:33 +0000 (12:41 +0200)
committerPablo Neira Ayuso <pablo@netfilter.org>
Wed, 24 Aug 2022 05:43:21 +0000 (07:43 +0200)
commit43eb8949cfdffa764b92bc6c54b87cbe5b0003fe
tree68e431d7d8a2c6712f08da121396a86a34b7665d
parent7044ab281febae9e2fa9b0b247693d6026166293
netfilter: nf_tables: do not leave chain stats enabled on error

Error might occur later in the nf_tables_addchain() codepath, enable
static key only after transaction has been created.

Fixes: 9f08ea848117 ("netfilter: nf_tables: keep chain counters away from hot path")
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
net/netfilter/nf_tables_api.c