Fix spurious assertion

This commit is contained in:
Jarred Sumner
2022-11-25 00:14:01 -08:00
parent ce2cdb44e1
commit 64871b2bfb

View File

@@ -109,7 +109,7 @@ const CAllocator = struct {
// so it's faster if we don't pass that value through
// but its good to have that assertion
if (comptime Environment.allow_assert) {
assert(mimalloc.mi_check_owned(buf.ptr));
assert(mimalloc.mi_is_in_heap_region(buf.ptr));
mimalloc.mi_free_size_aligned(buf.ptr, buf.len, buf_align);
} else {
mimalloc.mi_free(buf.ptr);