next up previous contents index
Next: 9.5.6 mustcalloc: allocate cleared Up: 9.5 Memory Allocation Previous: 9.5.4 memalign: allocate aligned

9.5.5 calloc: allocate cleared memory

   

SYNOPSIS

#include <oskit/c/malloc.h>

void *calloc(size_t nelt, size_t eltsize);

DESCRIPTION

Standard issue calloc function. Calls malloc to allocate the memory and memset to clear it.

PARAMETERS

nelt
Number of elements being allocated.
eltsize
Size of each element.

RETURNS

Returns a pointer to the allocated memory or zero if none.



University of Utah Flux Research Group