Function mi_realloc

Source
pub unsafe extern "C" fn mi_realloc(
    p: *mut c_void,
    new_size: usize,
) -> *mut c_void
Expand description

Reallocates memory to new_size bytes.

Returns a pointer to the allocated memory or null if out of memory.

If null is returned, the pointer p is not freed. Otherwise, the original pointer is either freed or returned as the result if the reallocation fits in-place with the new size.

If p is null, this is equivalent to mi_malloc. If new_size is larger than the original size allocated for p, the bytes after size are uninitialized.