I'm using mmap()
in my custom thread local memory allocator in order to reduce heap fragmentation.
For security reasons, it would be nice to detect if some memory breaks the boundary of its thread. Is it possible to make memory read-only for all other threads, so that I get a segmentation fault, when accessed by another thread.