diff options
author | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2022-05-12 17:03:07 +0200 |
---|---|---|
committer | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2022-05-12 17:15:51 +0200 |
commit | 7daeec3e6c8dc1b6ba917e9cc344a6e40221da4a (patch) | |
tree | 2e69e7ce574660d8cbd542a75b59f65152d20b50 /src/resolve/resolved-dns-packet.c | |
parent | resolved: add DNS_ANSWER_REPLACE (diff) | |
download | systemd-7daeec3e6c8dc1b6ba917e9cc344a6e40221da4a.tar.xz systemd-7daeec3e6c8dc1b6ba917e9cc344a6e40221da4a.zip |
resolved: add DNS_RR_REPLACE
Diffstat (limited to 'src/resolve/resolved-dns-packet.c')
-rw-r--r-- | src/resolve/resolved-dns-packet.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/resolve/resolved-dns-packet.c b/src/resolve/resolved-dns-packet.c index 50785a6823..d6fb4880b0 100644 --- a/src/resolve/resolved-dns-packet.c +++ b/src/resolve/resolved-dns-packet.c @@ -2359,8 +2359,7 @@ static int dns_packet_extract_answer(DnsPacket *p, DnsAnswer **ret_answer) { /* Remember this RR, so that we can potentially merge its ->key object with the * next RR. Note that we only do this if we actually decided to keep the RR around. */ - dns_resource_record_unref(previous); - previous = dns_resource_record_ref(rr); + DNS_RR_REPLACE(previous, dns_resource_record_ref(rr)); } if (bad_opt) { |