mi_realloc

Re-allocate memory to newsize bytes.

extern (C) @nogc pure @system nothrow
void*
mi_realloc
(
void* p
,
size_t newsize
)

Parameters

p void*

pointer to previously allocated memory (or NULL).

newsize size_t

the new required size in bytes.

Return Value

Type: void*

pointer to the re-allocated memory of newsize bytes, 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 reallocated result (in case it fits in-place with the new size). If the pointer p is NULL, it behaves as mi_malloc(newsize). If newsize is larger than the original size allocated for p, the bytes after size are uninitialized.

Meta