]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
fixup! fixup! fixup! fixup! Cleanups
authorAlessio Podda <alessio@isc.org>
Wed, 1 Oct 2025 09:35:52 +0000 (11:35 +0200)
committerAlessio Podda <alessio@isc.org>
Wed, 1 Oct 2025 09:35:52 +0000 (11:35 +0200)
lib/ns/include/ns/stats.h
lib/ns/stats.c

index cd6bc1f8b75cd933776c77b379b37ed0df402486..f366e2dd90e22cd4deb8b9d091d4abfbf4a19ba8 100644 (file)
@@ -124,19 +124,16 @@ enum {
        ns_statscounter_encryptedproxydot = 76,
        ns_statscounter_encryptedproxydoh = 77,
 
-       ns_statscounter_max = 80,
-};
+       ns_additive_count = 78,
 
-// XXX(ap): highwater counters
-enum {
        ns_statscounter_tcphighwater = 78,
        ns_statscounter_recurshighwater = 79,
 
-       ns_highwater_max = ns_statscounter_max,
+       ns_statscounter_max = 80,
 };
 
 enum {
-       ns_statscounter_total = ns_statscounter_max + ns_highwater_max,
+       ns_highwater_count = ns_statscounter_max - ns_additive_count,
 };
 
 void
index ad287aef439d9f9cacd1e3c389dfe8b0e0dcdd63..2e4d247bc071c3516b35291308f1d190ba8dfa2c 100644 (file)
@@ -23,11 +23,7 @@ void
 ns_stats_create(isc_mem_t *mctx, isc_statsmulti_t **statsp) {
        REQUIRE(statsp != NULL && *statsp == NULL);
 
-       /*
-        * Create ns statistics using statsmulti for better multithreading performance.
-        * We have 78 additive counters and ns_highwater_max highwater counters.
-        */
-       isc_statsmulti_create(mctx, statsp, 78, 2);
+       isc_statsmulti_create(mctx, statsp, ns_additive_count, ns_highwater_count);
 }
 
 /*%