2
0
mirror of https://gitlab.isc.org/isc-projects/bind9 synced 2025-08-31 06:25:31 +00:00

999. [func] "rndc retransfer zone [class [view]]" added.

[RT #1752]
This commit is contained in:
Mark Andrews
2001-09-15 14:23:29 +00:00
parent 5fe1a246cf
commit 5fe21da364
7 changed files with 49 additions and 6 deletions

View File

@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: server.c,v 1.342 2001/09/07 00:36:54 marka Exp $ */
/* $Id: server.c,v 1.343 2001/09/15 14:23:23 marka Exp $ */
#include <config.h>
@@ -2565,6 +2565,29 @@ zone_from_args(ns_server_t *server, char *args, dns_zone_t **zonep) {
return (result);
}
/*
* Act on a "retransfer" command from the command channel.
*/
isc_result_t
ns_server_retransfercommand(ns_server_t *server, char *args) {
isc_result_t result;
dns_zone_t *zone = NULL;
dns_zonetype_t type;
result = zone_from_args(server, args, &zone);
if (result != ISC_R_SUCCESS)
return (result);
if (zone == NULL)
return (ISC_R_UNEXPECTEDEND);
type = dns_zone_gettype(zone);
if (type == dns_zone_slave || type == dns_zone_stub)
dns_zone_forcereload(zone);
else
result = ISC_R_NOTFOUND;
dns_zone_detach(&zone);
return (result);
}
/*
* Act on a "reload" command from the command channel.
*/