]> git.ipfire.org Git - thirdparty/systemd.git/commit
dns-answer: preserve shared aliases when removing records 43011/head
authorLuca Boccassi <luca.boccassi@gmail.com>
Mon, 13 Jul 2026 14:04:35 +0000 (15:04 +0100)
committerLuca Boccassi <luca.boccassi@gmail.com>
Tue, 14 Jul 2026 09:09:31 +0000 (10:09 +0100)
commite509a6a4cb9846c9337f60b019b3d29a2bc8f7a3
treec1a3d04f49541392ee7b382183a671389d1df8b0
parent3734b69f030a0f7c9056ad094f3d97d7a561799c
dns-answer: preserve shared aliases when removing records

dns_answer_remove_by_rr() mutats the backing OrderedSet even when the answer
has multiple references. Callers such as trust-anchor revocation could thus
change snapshots held elsewhere in the resolver.

Clone a shared answer before removal.

Follow-up for 71aee23dba7faeef68e7232f444626267a6c90d7
src/resolve/test-dns-answer.c
src/shared/dns-answer.c