Skip to content
Snippets Groups Projects
Commit 5989fa8d authored by Christian Engwer's avatar Christian Engwer
Browse files

[debugallocator]

use posix_mprotect, which is also supported by mac-os-x

[[Imported from SVN: r7014]]
parent 51a2f27f
No related branches found
No related tags found
No related merge requests found
......@@ -107,8 +107,8 @@ namespace Dune
ai.pages = (ai.capacity) / page_size + 2;
ai.not_free = true;
size_type overlap = ai.capacity % page_size;
ai.page_ptr = memalign(page_size, ai.pages * page_size);
if (0 == ai.page_ptr)
int result = posix_memalign(&(ai.page_ptr), page_size, ai.pages * page_size);
if (0 != result)
{
throw std::bad_alloc();
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment