Closed
Description
The use of MAP_FIXED
flag in the dzmmap
functions means we overwrite any previous mapping that may overlap with our current request:
Line 15 in a4110d9
Although it is very unlikely to happen in 64-bits targets, it is still possible.
For example, we do not know how various malloc
implementations use the address space, and we may overwrite their mappings.
An alternative is to remove the MAP_FIXED
flag and compare the result of mmap with our requested starting address.
AFAIK, they will be the same if there is no overlaps.