]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
fix: dev: Fix resquery reference imbalance on TCP connect failure
authorOndřej Surý <ondrej@isc.org>
Tue, 10 Mar 2026 17:38:37 +0000 (18:38 +0100)
committerOndřej Surý <ondrej@isc.org>
Tue, 10 Mar 2026 17:38:37 +0000 (18:38 +0100)
In fctx_query(), resquery_ref(query) is called before
dns_dispatch_connect() in anticipation of the resquery_connected()
callback consuming the reference.  When dns_dispatch_connect() fails
synchronously on TCP (e.g. from dns_transport_get_tlsctx() failing
in tcp_dispatch_connect()), the connect callback is never scheduled,
so the extra reference is never consumed.  This has been fixed.

Merge branch 'ondrej/fix-resquery-refcount' into 'main'

See merge request isc-projects/bind9!11640


Trivial merge