mirror of
https://github.com/isc-projects/bind9.git
synced 2026-06-11 06:39:59 -04:00
fix: dev: Fix a bug in get_request_transport_type()
When `dns_remote_done()` is true, calling `dns_remote_curraddr()` asserts. Add a `dns_remote_curraddr()` check before calling `dns_remote_curraddr()`. Closes #5215 Merge branch '5215-assert-in-dns_remote_curraddr-fix' into 'main' See merge request isc-projects/bind9!10222
This commit is contained in:
commit
db5166ab99
1 changed files with 3 additions and 1 deletions
|
|
@ -18461,7 +18461,9 @@ get_request_transport_type(dns_zone_t *zone) {
|
|||
: DNS_TRANSPORT_UDP;
|
||||
|
||||
/* Check if the peer is forced to always use TCP. */
|
||||
if (transport_type != DNS_TRANSPORT_TCP) {
|
||||
if (transport_type != DNS_TRANSPORT_TCP &&
|
||||
!dns_remote_done(&zone->primaries))
|
||||
{
|
||||
isc_result_t result;
|
||||
isc_sockaddr_t primaryaddr;
|
||||
isc_netaddr_t primaryip;
|
||||
|
|
|
|||
Loading…
Reference in a new issue