]> git.ipfire.org Git - thirdparty/rspamd.git/commit
[Fix] Ensure stable re_cache class hashes independent of other classes
authorVsevolod Stakhov <vsevolod@rspamd.com>
Sat, 10 Jan 2026 17:19:32 +0000 (17:19 +0000)
committerVsevolod Stakhov <vsevolod@rspamd.com>
Sat, 10 Jan 2026 17:19:32 +0000 (17:19 +0000)
commite33192b83ea53ab2a8fb9a6240c4661e5978d45e
tree79cff4b7c29a7752966da1c6b2caf197f13aff78
parent1292994e6510e0946f7784fed2ca05e70dc6ff18
[Fix] Ensure stable re_cache class hashes independent of other classes

Previously, the global regexp index `i` was included in per-class hashes,
which caused class B's hash to change when class A got new regexps
(because indices shift). This made Redis caching ineffective as databases
were constantly being recompiled.

Now the global index is only included in the global hash, not in per-class
hashes, ensuring each class hash depends only on its own regexps.
src/libserver/re_cache.c