]> git.ipfire.org Git - thirdparty/nftables.git/commit
intervals: unset EXPR_F_KERNEL for adjusted elements
authorPablo Neira Ayuso <pablo@netfilter.org>
Wed, 13 Apr 2022 13:37:19 +0000 (15:37 +0200)
committerPablo Neira Ayuso <pablo@netfilter.org>
Wed, 13 Apr 2022 14:31:41 +0000 (16:31 +0200)
commitab1b21be54b2be4130f10dda7127aeca3195e252
tree682aaa06e7476df4faf73aea82a1f86bea69ac3a
parente0beff27435433ce2fd2826496774a539df73d65
intervals: unset EXPR_F_KERNEL for adjusted elements

This element is adjusted, reset the EXPR_F_KERNEL flag, this is a new
element and the old is purged from the kernel.

The existing list of elements in the kernel is spliced to the elements
to be removed, then merge-sorted. The EXPR_F_REMOVE flag specifies that
this element represents a deletion.

The EXPR_F_REMOVE and EXPR_F_KERNEL allows to track objects: whether
element is in the kernel (EXPR_F_KERNEL), element is new (no flag) or
element represents a removal (EXPR_F_REMOVE).

Reported-by: Phil Sutter <phil@nwl.cc>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
src/intervals.c