]> git.ipfire.org Git - thirdparty/bind9.git/commit
Do not re-add a node to the same prunenodes list
authorMichał Kępień <michal@isc.org>
Fri, 1 Mar 2024 17:12:37 +0000 (18:12 +0100)
committerMichał Kępień <michal@isc.org>
Fri, 1 Mar 2024 17:19:39 +0000 (18:19 +0100)
commit37101c7c8abbacaf07c30d5094bc6880cf4f7ca0
tree124a46ce6dc45f04ea47adcd84ba41bd477f10cf
parenta837ba5cd2760a92770f4b49e02ce82fdb2bcd94
Do not re-add a node to the same prunenodes list

If a node cleaned up by prune_tree() happens to belong to the same node
bucket as its parent, the latter is directly appended to the prunenodes
list currently processed by prune_tree().  However, the relevant code
branch does not account for the fact that the parent might already be on
the list it is trying to append it to.  Fix by only calling
ISC_LIST_APPEND() for parent nodes not yet added to their relevant
prunenodes list.

(cherry picked from commit 4b6fc97af6f936616a12e733b14ffc450af6df87)
lib/dns/rbtdb.c