2
0
mirror of https://gitlab.isc.org/isc-projects/bind9 synced 2025-08-29 21:47:59 +00:00

Add macro to initalise the common part of a rdata struct.

This commit is contained in:
Mark Andrews 2000-06-06 02:03:23 +00:00
parent d2b5fe92a4
commit ba6f0d85b4

View File

@ -31,3 +31,9 @@ typedef struct dns_rdatacommon {
ISC_LINK(struct dns_rdatacommon) link;
} dns_rdatacommon_t;
#define DNS_RDATACOMMON_INIT(DATA, RDTYPE, RDCLASS) \
do { \
(DATA)->common.rdtype = (RDTYPE); \
(DATA)->common.rdclass = (RDCLASS); \
ISC_LINK_INIT(&(DATA)->common, link); \
} while (0)