diff --git a/src/platform/allocator/dlmalloc.rs b/src/platform/allocator/dlmalloc.rs index a57748c7e00dbbdb06cc2f9b2bdf4a542ba59f1a..a5a890f7d37418c9e9d6cfedc23c3edfd53d7692 100644 --- a/src/platform/allocator/dlmalloc.rs +++ b/src/platform/allocator/dlmalloc.rs @@ -13,11 +13,11 @@ pub struct Allocator; unsafe impl<'a> GlobalAlloc for Allocator { unsafe fn alloc(&self, layout: Layout) -> *mut u8 { - dlmemalign(layout.align(), layout.size()) as *mut u8 + alloc_align(layout.size(), layout.align()) as *mut u8 } unsafe fn dealloc(&self, ptr: *mut u8, _layout: Layout) { - dlfree(ptr as *mut c_void) + free(ptr as *mut c_void) } }