mirror of
https://gitlab.isc.org/isc-projects/bind9
synced 2025-08-31 14:35:26 +00:00
3541. [bug] The parts if libdns was not being properly initialized
in when built in libexport mode. [RT #33028]
This commit is contained in:
@@ -80,8 +80,11 @@ typedef struct rdatasetheader {
|
||||
|
||||
/* Copied from rbtdb.c */
|
||||
#define RDATASET_ATTR_NXDOMAIN 0x0010
|
||||
#define RDATASET_ATTR_NEGATIVE 0x0100
|
||||
#define NXDOMAIN(header) \
|
||||
(((header)->attributes & RDATASET_ATTR_NXDOMAIN) != 0)
|
||||
#define NEGATIVE(header) \
|
||||
(((header)->attributes & RDATASET_ATTR_NEGATIVE) != 0)
|
||||
|
||||
static isc_result_t dns_ecdb_create(isc_mem_t *mctx, dns_name_t *origin,
|
||||
dns_dbtype_t type,
|
||||
@@ -406,6 +409,8 @@ bind_rdataset(dns_ecdb_t *ecdb, dns_ecdbnode_t *node,
|
||||
rdataset->trust = header->trust;
|
||||
if (NXDOMAIN(header))
|
||||
rdataset->attributes |= DNS_RDATASETATTR_NXDOMAIN;
|
||||
if (NEGATIVE(header))
|
||||
rdataset->attributes |= DNS_RDATASETATTR_NEGATIVE;
|
||||
|
||||
rdataset->private1 = ecdb;
|
||||
rdataset->private2 = node;
|
||||
@@ -469,6 +474,8 @@ addrdataset(dns_db_t *db, dns_dbnode_t *node, dns_dbversion_t *version,
|
||||
header->attributes = 0;
|
||||
if ((rdataset->attributes & DNS_RDATASETATTR_NXDOMAIN) != 0)
|
||||
header->attributes |= RDATASET_ATTR_NXDOMAIN;
|
||||
if ((rdataset->attributes & DNS_RDATASETATTR_NEGATIVE) != 0)
|
||||
header->attributes |= RDATASET_ATTR_NEGATIVE;
|
||||
ISC_LINK_INIT(header, link);
|
||||
ISC_LIST_APPEND(ecdbnode->rdatasets, header, link);
|
||||
|
||||
|
Reference in New Issue
Block a user