Skip to content

Commit e537977

Browse files
kswiecickibratpiorka
authored andcommitted
Fix disjoint pool memory poison macro
The poison memory macro definition is always defined, so an #ifdef check is insufficient.
1 parent 9f4cd2a commit e537977

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/pool/pool_disjoint.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,14 +40,14 @@
4040

4141
static inline void annotate_memory_inaccessible([[maybe_unused]] void *ptr,
4242
[[maybe_unused]] size_t size) {
43-
#ifdef POISON_MEMORY
43+
#if (POISON_MEMORY != 0)
4444
utils_annotate_memory_inaccessible(ptr, size);
4545
#endif
4646
}
4747

4848
static inline void annotate_memory_undefined([[maybe_unused]] void *ptr,
4949
[[maybe_unused]] size_t size) {
50-
#ifdef POISON_MEMORY
50+
#if (POISON_MEMORY != 0)
5151
utils_annotate_memory_undefined(ptr, size);
5252
#endif
5353
}

0 commit comments

Comments
 (0)