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

removed code for hint, forward, and cache "zones" as those

no longer have zone objects associated with them
This commit is contained in:
Andreas Gustafsson 2000-05-25 21:07:43 +00:00
parent 51ef9c7d6c
commit e6aae9483e
2 changed files with 3 additions and 31 deletions

View File

@ -33,10 +33,7 @@ typedef enum {
dns_zone_none,
dns_zone_master,
dns_zone_slave,
dns_zone_hint,
dns_zone_stub,
dns_zone_cache,
dns_zone_forward
dns_zone_stub
} dns_zonetype_t;
#define DNS_ZONE_O_SERVERS 0x00000001U /* perform server checks */

View File

@ -15,7 +15,7 @@
* SOFTWARE.
*/
/* $Id: zone.c,v 1.127 2000/05/25 15:34:23 gson Exp $ */
/* $Id: zone.c,v 1.128 2000/05/25 21:05:43 gson Exp $ */
#include <config.h>
@ -581,16 +581,9 @@ dns_zone_validate(dns_zone_t *zone) {
case dns_zone_master:
case dns_zone_slave:
case dns_zone_stub:
case dns_zone_hint:
REQUIRE(zone->dbname != NULL);
/*FALLTHROUGH*/
case dns_zone_forward:
REQUIRE(zone->rdclass != dns_rdataclass_none);
break;
case dns_zone_cache:
REQUIRE(zone->rdclass == dns_rdataclass_none);
REQUIRE(zone->dbname == NULL);
break;
}
REQUIRE(zone->db_type != NULL);
@ -603,7 +596,6 @@ dns_zone_load(dns_zone_t *zone) {
unsigned int nscount = 0;
isc_uint32_t serial, refresh, retry, expire, minimum;
isc_result_t result;
isc_boolean_t cache = ISC_FALSE;
dns_rdata_soa_t soa;
isc_stdtime_t now;
isc_time_t loadtime, filetime;
@ -615,18 +607,12 @@ dns_zone_load(dns_zone_t *zone) {
isc_stdtime_get(&now);
switch (zone->type) {
case dns_zone_forward:
case dns_zone_none:
result = ISC_R_SUCCESS;
goto cleanup;
case dns_zone_master:
case dns_zone_slave:
case dns_zone_stub:
case dns_zone_hint:
cache = ISC_FALSE;
break;
case dns_zone_cache:
cache = ISC_TRUE;
break;
default:
INSIST("bad zone type" == NULL);
@ -662,7 +648,7 @@ dns_zone_load(dns_zone_t *zone) {
result = dns_db_create(zone->mctx, zone->db_type,
&zone->origin,
cache, zone->rdclass,
ISC_FALSE, zone->rdclass,
zone->db_argc, zone->db_argv, &db);
if (result != ISC_R_SUCCESS)
@ -732,8 +718,6 @@ dns_zone_load(dns_zone_t *zone) {
/*
* Master / Slave / Stub zones require both NS and SOA records at
* the top of the zone.
* Hint zones only require NS records.
* Cache zones have no reqirements.
*/
switch (zone->type) {
@ -778,15 +762,6 @@ dns_zone_load(dns_zone_t *zone) {
zone->refreshtime = now;
}
break;
case dns_zone_hint:
if (nscount == 0) {
zone_log(zone, me, ISC_LOG_ERROR, "no NS records");
result = DNS_R_BADZONE;
goto cleanup;
}
break;
case dns_zone_cache:
break;
default:
UNEXPECTED_ERROR(__FILE__, __LINE__,
"unexpected zone type %d", zone->type);