Index of Section 3 Manual Pages
| Interix / SUA | free.3 | Interix / SUA |
free(3) free(3)
free()
NAME
free() - free up memory allocated with malloc, calloc or realloc
SYNOPSIS
#include
void free (void *ptr)
DESCRIPTION
The free(3) function causes the space pointed to by ptr to be deallocated,
that is, made available for further allocation. If ptr is a NULL pointer,
no action occurs. Otherwise, if the argument does not match a pointer
earlier returned by the calloc(3), malloc(3), or realloc(3) function, or
if the space has been deallocated by a call to free(3) or realloc(3),
problems may result.
RETURN VALUES
The free(3) function returns no value.
SEE ALSO
calloc(3)
malloc(3)
realloc(3)
USAGE NOTES
The free function is thread safe.
The free function is not async-signal safe.