#223 Remove rpz_attach for BIND 9.16+
Merged a year ago by abbra. Opened a year ago by pemensik.
pemensik/bind-dyndb-ldap rpz-db_registered-delete  into  master

file modified
-8
@@ -160,14 +160,6 @@ 

  [AC_MSG_ERROR([Cross compiling is not supported.])]

  )

  

- # Check db_registered

- AC_CHECK_HEADER(dns/rpz.h, [], [AC_MSG_ERROR([dns/rpz.h not found])])

- AC_CHECK_MEMBER([struct dns_rpz_zone.db_registered],

-                 [AC_DEFINE([HAVE_DB_REGISTERED], [1],

-                            [Struct dns_rpz_zone has db_registered])],

-                 [AC_MSG_NOTICE([Struct dns_rpz_zone has no db_registered])],

-                 [[#include <dns/rpz.h>]])

- 

  dnl dns_db_setservestalettl() can be backported, detect support

  AC_CHECK_LIB([dns], [dns_db_setservestalettl],

    [AC_DEFINE([HAVE_DNS_SERVESTALE], 1, [Define if dns library provides dns_db_setservestalettl])]

file modified
+4 -18
@@ -804,24 +804,6 @@ 

  

  	dns_db_rpz_attach(ldapdb->rbtdb, rpzs, rpz_num);

  }

- #else

- void

- rpz_attach(dns_db_t *db, void *void_rpzs, uint8_t rpz_num)

- {

- 	ldapdb_t *ldapdb = (ldapdb_t *) db;

- 	dns_rpz_zones_t *rpzs = (dns_rpz_zones_t *) void_rpzs;

- 	isc_result_t result;

- 

- 	REQUIRE(VALID_LDAPDB(ldapdb));

- 

- #if defined(HAVE_DB_REGISTERED)

- 	rpzs->zones[rpz_num]->db_registered = true;

- #endif

- 	result = dns_db_updatenotify_register(ldapdb->rbtdb,

- 					      dns_rpz_dbupdate_callback,

- 					      rpzs->zones[rpz_num]);

- 	REQUIRE(result == ISC_R_SUCCESS);

- }

  #endif

  

  /*
@@ -968,7 +950,11 @@ 

  	resigned,

  	isdnssec,

  	getrrsetstats,

+ #if LIBDNS_VERSION_MAJOR < 1600

  	rpz_attach,

+ #else

+ 	NULL,

+ #endif

  	NULL, /* rpz_ready */

  	findnodeext,

  	findext,

rpz_attach is never supplied from BIND9 code both in 9.16 or 9.18.
Remove our custom function and pass NULL as well. It would be never
called anyway.

I would prefer if you'd rebase your commit to avoid reverting the db_registered change.
That would be more logical -- removing explicitly already working code.

rebased onto 1be5722

a year ago

Okay, just squashed those commits together and adjusted message a bit.

Pull-Request has been merged by abbra

a year ago
Metadata