]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
[9.20] fix: dev: Don't skip the counting if fcount_incr() is called with force==true...
authorOndřej Surý <ondrej@isc.org>
Tue, 13 Aug 2024 14:53:28 +0000 (14:53 +0000)
committerOndřej Surý <ondrej@isc.org>
Tue, 13 Aug 2024 14:53:28 +0000 (14:53 +0000)
The fcount_incr() was not increasing counter->count when force was set
to true, but fcount_decr() would try to decrease the counter leading to
underflow and assertion failure.  Swap the order of the arguments in the
condition, so the !force is evaluated after incrementing the .count.

Closes #4846

Backport of MR !9298

Merge branch 'backport-4786-forced-fcount_incr-should-increment-count-and-allowed-fix-9.20' into 'bind-9.20'

See merge request isc-projects/bind9!9299


Trivial merge