pub unsafe fn realloc(buffer: *mut c_void, new_size: usize) -> *mut c_void
This wraps libc::realloc and is only safe to call with a pointer value that is NULL or allocated through malloc / realloc.