rpmalloc: Disable assert on failing to map memory.

We want applications to be able to handle out-of-memory
conditions gracefully, not just trigger an assert every time.
I disabled this before, looks like I missed it in the final
patch.
This commit is contained in:
Augustin Cavalier
2019-05-17 16:35:58 -04:00
parent dd249016c2
commit fb683851b1
@@ -1726,7 +1726,9 @@ _memory_map_os(size_t size, size_t* offset) {
void* ptr = mmap(0, size + padding, PROT_READ | PROT_WRITE, MAP_PRIVATE | MAP_ANONYMOUS | MAP_UNINITIALIZED, -1, 0);
# endif
if ((ptr == MAP_FAILED) || !ptr) {
#ifndef __HAIKU__
assert("Failed to map virtual memory block" == 0);
#endif
return 0;
}
#endif