Commit e0bb2ec2 authored by Witold Krecicki's avatar Witold Krecicki Committed by Ondřej Surý
Browse files

In developer mode assert if statistics counter underflows

parent 78a4ed31
......@@ -115,7 +115,11 @@ void
isc_stats_decrement(isc_stats_t *stats, isc_statscounter_t counter) {
REQUIRE(counter < stats->ncounters);
#ifndef NDEBUG
REQUIRE(atomic_fetch_sub_release(&stats->counters[counter], 1) > 0);
atomic_fetch_sub_release(&stats->counters[counter], 1);
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment