diff --git a/bin/named/include/named/types.h b/bin/named/include/named/types.h index 1de8253d49..a4d3816b03 100644 --- a/bin/named/include/named/types.h +++ b/bin/named/include/named/types.h @@ -26,27 +26,4 @@ typedef struct ns_client ns_client_t; typedef struct ns_clientmgr ns_clientmgr_t; typedef struct ns_query ns_query_t; -/* - * XXXRTH This stuff is temporary. As soon as we have zone and config - * support, it will go away. - */ - -typedef struct ns_dbinfo { - char * path; - char * origin; - char * master; /* Dotted quad, or NULL */ - isc_boolean_t iscache; - isc_boolean_t isslave; - dns_view_t * view; - dns_zone_t * zone; - dns_db_t * db; - ISC_LINK(struct ns_dbinfo) link; -} ns_dbinfo_t; - -typedef ISC_LIST(ns_dbinfo_t) ns_dbinfolist_t; - -/* - * XXXRTH End of temporary stuff. - */ - #endif /* NS_TYPES_H */ diff --git a/bin/named/main.c b/bin/named/main.c index 314de49861..4c4165b766 100644 --- a/bin/named/main.c +++ b/bin/named/main.c @@ -115,34 +115,13 @@ usage(void) { static void parse_command_line(int argc, char *argv[]) { - char *argtext, *mastertext, *origintext; int ch; - ns_dbinfo_t *dbi; while ((ch = isc_commandline_parse(argc, argv, "b:c:N:p:sz:")) != -1) { switch (ch) { case 'b': - ns_g_conffile = isc_commandline_argument; - break; case 'c': - /* XXXRTH temporary syntax */ - dbi = isc_mem_get(ns_g_mctx, sizeof *dbi); - if (dbi == NULL) - early_fatal("creating cache info failed"); - dbi->path = isc_mem_strdup(ns_g_mctx, - isc_commandline_argument); - if (dbi->path == NULL) - early_fatal("out of memory"); - dbi->origin = isc_mem_strdup(ns_g_mctx, "."); - if (dbi->origin == NULL) - early_fatal("out of memory"); - dbi->master = NULL; - dbi->iscache = ISC_TRUE; - dbi->isslave = ISC_FALSE; - dbi->view = NULL; - dbi->db = NULL; - ISC_LINK_INIT(dbi, link); - ISC_LIST_APPEND(ns_g_dbs, dbi, link); + ns_g_conffile = isc_commandline_argument; break; case 'N': ns_g_cpus = atoi(isc_commandline_argument); @@ -156,49 +135,6 @@ parse_command_line(int argc, char *argv[]) { /* XXXRTH temporary syntax */ want_stats = ISC_TRUE; break; - case 'z': - /* XXXRTH temporary syntax */ - dbi = isc_mem_get(ns_g_mctx, sizeof *dbi); - if (dbi == NULL) - early_fatal("creating zone info failed"); - argtext = isc_mem_strdup(ns_g_mctx, - isc_commandline_argument); - if (argtext == NULL) - early_fatal("out of memory"); - mastertext = strrchr(argtext, '@'); - if (mastertext == NULL) { - dbi->master = NULL; - dbi->isslave = ISC_FALSE; - } else { - *mastertext++ = '\0'; - dbi->master = isc_mem_strdup(ns_g_mctx, - mastertext); - if (dbi->master == NULL) - early_fatal("out of memory"); - - RUNTIME_CHECK(dbi->master != NULL); - dbi->isslave = ISC_TRUE; - } - - origintext = strrchr(argtext, '/'); - if (origintext == NULL) - origintext = argtext; - else - origintext++; /* Skip '/'. */ - - dbi->path = isc_mem_strdup(ns_g_mctx, argtext); - if (dbi->path == NULL) - early_fatal("out of memory"); - dbi->origin = isc_mem_strdup(ns_g_mctx, origintext); - if (dbi->origin == NULL) - early_fatal("out of memory"); - dbi->view = NULL; - dbi->db = NULL; - dbi->iscache = ISC_FALSE; - isc_mem_free(ns_g_mctx, argtext); - ISC_LINK_INIT(dbi, link); - ISC_LIST_APPEND(ns_g_dbs, dbi, link); - break; case '?': usage(); early_fatal("unknown command line argument");