commit 257cce0: [Minor] Fix flags bitops
Vsevolod Stakhov
vsevolod at rspamd.com
Sun May 1 12:07:03 UTC 2022
Author: Vsevolod Stakhov
Date: 2022-05-01 12:42:10 +0100
URL: https://github.com/rspamd/rspamd/commit/257cce09f7f43f3b626200c31cac35838c35a253
[Minor] Fix flags bitops
---
src/libserver/symcache/symcache_item.cxx | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/libserver/symcache/symcache_item.cxx b/src/libserver/symcache/symcache_item.cxx
index 635dc6324..dbcd66690 100644
--- a/src/libserver/symcache/symcache_item.cxx
+++ b/src/libserver/symcache/symcache_item.cxx
@@ -357,7 +357,7 @@ auto item_type_from_c(enum rspamd_symbol_type type) -> tl::expected<std::pair<sy
| SYMBOL_TYPE_VIRTUAL;
constexpr auto all_but_one_ty = [&](int type, int exclude_bit) -> auto {
- return type & (trivial_types & ~exclude_bit);
+ return (type & trivial_types) & (trivial_types & ~exclude_bit);
};
if (type & trivial_types) {
More information about the Commits
mailing list