mirror of
https://github.com/isc-projects/bind9.git
synced 2026-06-04 20:12:04 -04:00
Use an accessor fuction to access find->status
find->status is marked as private and access is controlled
by find->lock.
(cherry picked from commit c900300f21)
This commit is contained in:
parent
a348077718
commit
ce6c0c26a0
3 changed files with 23 additions and 1 deletions
|
|
@ -2324,6 +2324,18 @@ dns_adb_cancelfind(dns_adbfind_t *find) {
|
|||
}
|
||||
}
|
||||
|
||||
unsigned int
|
||||
dns_adb_findstatus(dns_adbfind_t *find) {
|
||||
unsigned int status;
|
||||
REQUIRE(DNS_ADBFIND_VALID(find));
|
||||
|
||||
UNLOCK(&find->lock);
|
||||
status = find->status;
|
||||
UNLOCK(&find->lock);
|
||||
|
||||
return (status);
|
||||
}
|
||||
|
||||
void
|
||||
dns_adb_dump(dns_adb_t *adb, FILE *f) {
|
||||
isc_stdtime_t now = isc_stdtime_now();
|
||||
|
|
|
|||
|
|
@ -387,6 +387,16 @@ dns_adbfind_done(dns_adbfind_t find);
|
|||
*\li 'find' != NULL and *find be valid dns_adbfind_t pointer.
|
||||
*/
|
||||
|
||||
unsigned int
|
||||
dns_adb_findstatus(dns_adbfind_t *);
|
||||
/*%<
|
||||
* Returns the status field of the find.
|
||||
*
|
||||
* Requires:
|
||||
*
|
||||
*\li 'find' be a valid dns_adbfind_t pointer.
|
||||
*/
|
||||
|
||||
void
|
||||
dns_adb_destroyfind(dns_adbfind_t **find);
|
||||
/*%<
|
||||
|
|
|
|||
|
|
@ -2910,7 +2910,7 @@ fctx_finddone(void *arg) {
|
|||
* The fetch is waiting for a name to be found.
|
||||
*/
|
||||
INSIST(!SHUTTINGDOWN(fctx));
|
||||
if (find->status == DNS_ADB_MOREADDRESSES) {
|
||||
if (dns_adb_findstatus(find) == DNS_ADB_MOREADDRESSES) {
|
||||
FCTX_ATTR_CLR(fctx, FCTX_ATTR_ADDRWAIT);
|
||||
want_try = true;
|
||||
} else {
|
||||
|
|
|
|||
Loading…
Reference in a new issue