mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
builtin: use dlmalloc for -freestanding
(#13054)
This commit is contained in:
@ -54,7 +54,7 @@ pub fn realloc(ptr voidptr, oldsize usize, newsize usize) voidptr {
|
||||
[unsafe]
|
||||
pub fn memalign(size usize, align usize) voidptr {
|
||||
unsafe {
|
||||
if align <= malloc_alignment {
|
||||
if align <= malloc_alignment() {
|
||||
return global.malloc(size)
|
||||
} else {
|
||||
return global.memalign(align, size)
|
||||
|
Reference in New Issue
Block a user