mirror of
https://gitlab.isc.org/isc-projects/bind9
synced 2025-09-01 15:05:23 +00:00
[9.20] 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 Backport of MR !10222 Merge branch 'backport-5215-assert-in-dns_remote_curraddr-fix-9.20' into 'bind-9.20' See merge request isc-projects/bind9!10223
This commit is contained in:
@@ -18312,7 +18312,9 @@ get_request_transport_type(dns_zone_t *zone) {
|
|||||||
: DNS_TRANSPORT_UDP;
|
: DNS_TRANSPORT_UDP;
|
||||||
|
|
||||||
/* Check if the peer is forced to always use TCP. */
|
/* 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_result_t result;
|
||||||
isc_sockaddr_t primaryaddr;
|
isc_sockaddr_t primaryaddr;
|
||||||
isc_netaddr_t primaryip;
|
isc_netaddr_t primaryip;
|
||||||
|
Reference in New Issue
Block a user