diff --git a/lib/dns/include/dns/stats.h b/lib/dns/include/dns/stats.h index e6e39775ad..5728f54ff0 100644 --- a/lib/dns/include/dns/stats.h +++ b/lib/dns/include/dns/stats.h @@ -444,22 +444,6 @@ enum { dns_sizecounter_out_max = 257 }; -#define DNS_STATS_NCOUNTERS 8 - -#if 0 -/*%< - * Flag(s) for dns_xxxstats_dump(). DNS_STATSDUMP_VERBOSE is obsolete. - * ISC_STATSDUMP_VERBOSE should be used instead. These two values are - * intentionally defined to be the same value to ensure binary compatibility. - */ -#define DNS_STATSDUMP_VERBOSE 0x00000001 /*%< dump 0-value counters */ -#endif /* if 0 */ - -/*%< - * (Obsoleted) - */ -extern const char *dns_statscounter_names[]; - /*% * Attributes for statistics counters of RRset and Rdatatype types. * @@ -803,22 +787,4 @@ dns_rcodestats_dump(dns_stats_t *stats, dns_rcodestats_dumper_t dump_fn, *\li 'stats' is a valid dns_stats_t created by dns_generalstats_create(). */ -isc_result_t -dns_stats_alloccounters(isc_mem_t *mctx, uint64_t **ctrp); -/*%< - * Allocate an array of query statistics counters from the memory - * context 'mctx'. - * - * This function is obsoleted. Use dns_xxxstats_create() instead. - */ - -void -dns_stats_freecounters(isc_mem_t *mctx, uint64_t **ctrp); -/*%< - * Free an array of query statistics counters allocated from the memory - * context 'mctx'. - * - * This function is obsoleted. Use dns_stats_destroy() instead. - */ - ISC_LANG_ENDDECLS diff --git a/lib/dns/stats.c b/lib/dns/stats.c index c84f830f81..4a8eb32f24 100644 --- a/lib/dns/stats.c +++ b/lib/dns/stats.c @@ -618,31 +618,3 @@ dns_rcodestats_dump(dns_stats_t *stats, dns_rcodestats_dumper_t dump_fn, arg.arg = arg0; isc_stats_dump(stats->counters, rcode_dumpcb, &arg, options); } - -/*** - *** Obsolete variables and functions follow: - ***/ -const char *dns_statscounter_names[DNS_STATS_NCOUNTERS] = { - "success", "referral", "nxrrset", "nxdomain", - "recursion", "failure", "duplicate", "dropped" -}; - -isc_result_t -dns_stats_alloccounters(isc_mem_t *mctx, uint64_t **ctrp) { - int i; - uint64_t *p = isc_mem_get(mctx, DNS_STATS_NCOUNTERS * sizeof(uint64_t)); - if (p == NULL) { - return (ISC_R_NOMEMORY); - } - for (i = 0; i < DNS_STATS_NCOUNTERS; i++) { - p[i] = 0; - } - *ctrp = p; - return (ISC_R_SUCCESS); -} - -void -dns_stats_freecounters(isc_mem_t *mctx, uint64_t **ctrp) { - isc_mem_put(mctx, *ctrp, DNS_STATS_NCOUNTERS * sizeof(uint64_t)); - *ctrp = NULL; -}