mirror of
https://git.haproxy.org/git/haproxy.git/
synced 2025-11-28 14:21:00 +01:00
BUG/MEDIUM: pattern: Pattern node has type of "struct pat_idx_elt" in place of "struct eb_node"
The free() function must free the "struct pat_idx_elt". This bug was introduced by commit ed66c29 (REORG: acl/pattern: extract pattern matching from the acl file and create pattern.c), no backport is needed.
This commit is contained in:
parent
9667a80676
commit
3ce88c76a0
@ -769,11 +769,14 @@ void free_pattern_list(struct list *head)
|
||||
void free_pattern_tree(struct eb_root *root)
|
||||
{
|
||||
struct eb_node *node, *next;
|
||||
struct pat_idx_elt *elt;
|
||||
|
||||
node = eb_first(root);
|
||||
while (node) {
|
||||
next = eb_next(node);
|
||||
eb_delete(node);
|
||||
free(node);
|
||||
elt = container_of(node, struct pat_idx_elt, node);
|
||||
free(elt);
|
||||
node = next;
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user