From: Alessio Podda Date: Wed, 1 Apr 2026 10:13:08 +0000 (+0200) Subject: Make dns_glue_t private to qpzone X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d7a5a2e86b9b8b751fd54d1752cf7c7789ca6338;p=thirdparty%2Fbind9.git Make dns_glue_t private to qpzone The dns_glue_t, dns_gluelist_t and dns_glue_additionaldata_ctx types are only used in qpzone.c. This commits moves them to the private header qpzone_p.h. This is done in preparation of a followup commit that will refactor them to use types that are private to qpzone. --- diff --git a/lib/dns/db_p.h b/lib/dns/db_p.h index 630873e6b1e..a77acd0fda9 100644 --- a/lib/dns/db_p.h +++ b/lib/dns/db_p.h @@ -17,7 +17,6 @@ #include #include -#include #include #ifdef STRONG_RWLOCK_CHECK @@ -85,35 +84,6 @@ #define IS_STUB(db) (((db)->common.attributes & DNS_DBATTR_STUB) != 0) #define IS_CACHE(db) (((db)->common.attributes & DNS_DBATTR_CACHE) != 0) -struct dns_glue { - struct dns_glue *next; - dns_name_t name; - dns_rdataset_t rdataset_a; - dns_rdataset_t sigrdataset_a; - dns_rdataset_t rdataset_aaaa; - dns_rdataset_t sigrdataset_aaaa; -}; - -struct dns_gluelist { - isc_mem_t *mctx; - - const dns_dbversion_t *version; - dns_vecheader_t *header; - - struct dns_glue *glue; - - struct rcu_head rcu_head; - struct cds_wfs_node wfs_node; -}; - -typedef struct dns_glue_additionaldata_ctx { - dns_db_t *db; - dns_dbversion_t *version; - const dns_name_t *owner_name; - - dns_glue_t *glue; -} dns_glue_additionaldata_ctx_t; - static inline bool prio_type(dns_typepair_t type) { switch (type) { diff --git a/lib/dns/include/dns/rdataslab.h b/lib/dns/include/dns/rdataslab.h index 40ccb47e68c..a8d1a09a36e 100644 --- a/lib/dns/include/dns/rdataslab.h +++ b/lib/dns/include/dns/rdataslab.h @@ -119,11 +119,6 @@ struct dns_slabheader { */ dns_dbnode_t *node; - /*% - * Cached glue records for an rdataset of type NS (zone only). - */ - dns_gluelist_t *gluelist; - /*% * Case vector. If the bit is set then the corresponding * character in the owner name needs to be AND'd with 0x20, diff --git a/lib/dns/qpzone_p.h b/lib/dns/qpzone_p.h index 93d0782fef0..e000d102bf9 100644 --- a/lib/dns/qpzone_p.h +++ b/lib/dns/qpzone_p.h @@ -19,8 +19,39 @@ #include #include +#include #include +struct dns_glue { + struct dns_glue *next; + dns_name_t name; + dns_rdataset_t rdataset_a; + dns_rdataset_t sigrdataset_a; + dns_rdataset_t rdataset_aaaa; + dns_rdataset_t sigrdataset_aaaa; + bool required; +}; + +struct dns_gluelist { + isc_mem_t *mctx; + + const dns_dbversion_t *version; + dns_vecheader_t *header; + + struct dns_glue *glue; + + struct rcu_head rcu_head; + struct cds_wfs_node wfs_node; +}; + +typedef struct dns_glue_additionaldata_ctx { + dns_db_t *db; + dns_dbversion_t *version; + const dns_name_t *owner_name; + + dns_glue_t *glue; +} dns_glue_additionaldata_ctx_t; + /***** ***** Module Info *****/