mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/
synced 2026-10-18 19:12:56 +00:00
netfilter: nf_tables: fix error handling of rule replacement
commit 59900e0a01 upstream.
In general, if a transaction object is added to the list successfully,
we can rely on the abort path to undo what we've done. This allows us to
simplify the error handling of the rule replacement path in
nf_tables_newrule().
This implicitly fixes an unnecessary removal of the old rule, which
needs to be left in place if we fail to replace.
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Signed-off-by: Luis Henriques <luis.henriques@canonical.com>
This commit is contained in:
parent
5e8a1326f7
commit
c55a5bde67
1 changed files with 0 additions and 6 deletions
Loading…
Add table
Add a link
Reference in a new issue