Fix uninitialized value in downstream patch for dig/host

This was leading to incorrectly canceled queries in certain scenarios.

Resolves: RHEL-212648
This commit is contained in:
Fedor Vorobev 2026-07-20 18:26:00 +02:00
parent e2f39225fc
commit cfa78fe2a3
2 changed files with 22 additions and 11 deletions

View File

@ -1,5 +1,5 @@
diff --git a/bin/dig/dighost.c b/bin/dig/dighost.c
index ac7e1fb55b..d27c7979a0 100644
index ac7e1fb55b..9f1a05ea10 100644
--- a/bin/dig/dighost.c
+++ b/bin/dig/dighost.c
@@ -1571,6 +1571,31 @@ check_if_done(void) {
@ -34,15 +34,22 @@ index ac7e1fb55b..d27c7979a0 100644
/*%
* Clear out a query when we're done with it. WARNING: This routine
* WILL invalidate the query pointer.
@@ -2557,7 +2582,6 @@ setup_lookup(dig_lookup_t *lookup) {
@@ -2557,12 +2582,13 @@ setup_lookup(dig_lookup_t *lookup) {
query->waiting_senddone = false;
query->pending_free = false;
query->recv_made = false;
- query->first_pass = true;
+ query->started = false;
query->first_soa_rcvd = false;
query->second_rr_rcvd = false;
query->first_repeat_rcvd = false;
@@ -2660,6 +2684,7 @@ cancel_lookup(dig_lookup_t *lookup) {
query->warn_id = true;
query->timedout = false;
+ query->canceled = false;
query->first_rr_serial = 0;
query->second_rr_serial = 0;
query->servname = serv->servername;
@@ -2660,6 +2686,7 @@ cancel_lookup(dig_lookup_t *lookup) {
while (query != NULL) {
REQUIRE(DIG_VALID_QUERY(query));
next = ISC_LIST_NEXT(query, link);
@ -50,7 +57,7 @@ index ac7e1fb55b..d27c7979a0 100644
if (query->sock != NULL) {
isc_socket_cancel(query->sock, global_task,
ISC_SOCKCANCEL_ALL);
@@ -2902,6 +2927,12 @@ send_udp(dig_query_t *query) {
@@ -2902,6 +2929,12 @@ send_udp(dig_query_t *query) {
return;
}
@ -63,7 +70,7 @@ index ac7e1fb55b..d27c7979a0 100644
result = isc_socket_create(socketmgr,
isc_sockaddr_pf(&query->sockaddr),
isc_sockettype_udp, &query->sock);
@@ -3028,6 +3059,10 @@ connect_timeout(isc_task_t *task, isc_event_t *event) {
@@ -3028,6 +3061,10 @@ connect_timeout(isc_task_t *task, isc_event_t *event) {
clear_query(query);
}
}
@ -74,7 +81,7 @@ index ac7e1fb55b..d27c7979a0 100644
UNLOCK_LOOKUP;
return;
}
@@ -3283,6 +3318,14 @@ connect_done(isc_task_t *task, isc_event_t *event) {
@@ -3283,6 +3320,14 @@ connect_done(isc_task_t *task, isc_event_t *event) {
query = sevent->ev_arg;
REQUIRE(DIG_VALID_QUERY(query));
@ -89,7 +96,7 @@ index ac7e1fb55b..d27c7979a0 100644
INSIST(query->waiting_connect);
query->waiting_connect = false;
@@ -4004,6 +4047,9 @@ recv_done(isc_task_t *task, isc_event_t *event) {
@@ -4004,6 +4049,9 @@ recv_done(isc_task_t *task, isc_event_t *event) {
: "recursion not available",
query->servname);
clear_query(query);
@ -99,7 +106,7 @@ index ac7e1fb55b..d27c7979a0 100644
check_next_lookup(l);
dns_message_detach(&msg);
isc_event_free(&event);
@@ -4129,7 +4175,12 @@ recv_done(isc_task_t *task, isc_event_t *event) {
@@ -4129,7 +4177,12 @@ recv_done(isc_task_t *task, isc_event_t *event) {
l->trace_root = false;
usesearch = false;
} else {
@ -112,7 +119,7 @@ index ac7e1fb55b..d27c7979a0 100644
}
}
}
@@ -4309,6 +4360,7 @@ cancel_all(void) {
@@ -4309,6 +4362,7 @@ cancel_all(void) {
nq = ISC_LIST_NEXT(q, link);
debug("canceling pending query %p, belonging to %p", q,
current_lookup);
@ -120,7 +127,7 @@ index ac7e1fb55b..d27c7979a0 100644
if (q->sock != NULL) {
isc_socket_cancel(q->sock, NULL,
ISC_SOCKCANCEL_ALL);
@@ -4322,6 +4374,7 @@ cancel_all(void) {
@@ -4322,6 +4376,7 @@ cancel_all(void) {
nq = ISC_LIST_NEXT(q, clink);
debug("canceling connecting query %p, belonging to %p",
q, current_lookup);

View File

@ -54,7 +54,7 @@ Summary: The Berkeley Internet Name Domain (BIND) DNS (Domain Name System) serv
Name: bind
License: MPLv2.0
Version: 9.16.50
Release: 3%{?dist}
Release: 4%{?dist}
Epoch: 32
Url: https://www.isc.org/downloads/bind/
#
@ -1222,6 +1222,10 @@ fi;
%endif
%changelog
* Mon Jul 20 2026 Fedor Vorobev <fvorobev@redhat.com> - 32:9.16.50-4
- Fix uninitialized boolean in dig/host downstream patch that was
leading to incorrectly canceled queries in certain scenarios. (RHEL-212648)
* Tue Jul 7 2026 Fedor Vorobev <fvorobev@redhat.com> - 32:9.16.50-3
- Added CNAME chain bugfixes from v9.18.
- Fixed masterformat, reclimit, resolver, and qmin tests.