free() General Function free() Return dynamic memory to free memory pool void free(ptr) char *ptr; free helps you manage the arena. It returns to the free memory pool memory that had previously been allocated by malloc, calloc, or realloc. free marks the block indicated by ptr as unused, so the malloc search can coalesce it with contiguous free blocks. ptr must have been obtained from malloc, calloc, or realloc. ***** Example ***** For an example of how to use this routine, see the entry for malloc. ***** See Also ***** arena, calloc(), general functions, malloc(), realloc(), setbuf() ***** Diagnostics ***** free prints a message and calls abort if it discovers that the arena has been corrupted. This most often occurs by storing data beyond the bounds of an allocated block. COHERENT Lexicon Page 1