calloc

Allocates an area of zeroed memory. This function is AST-reentrant.

Format

#include  <stdlib.h>

void *calloc  (size_t number, size_t size);
Function Variants This function also has variants named _calloc32 and _calloc64 for use with 32-bit and 64-bit pointer sizes, respectively. See Section 1.8 for more information on using pointer-size-specific functions.

Arguments

number
The number of items to be allocated.
size
The size of each item.

Description

The calloc function initializes the items to 0.

See also malloc and realloc in this section.

Return Values
The address of the first byte, which is aligned on a quadword boundary. 
NULL  Indicates an inability to allocate the space. 


Previous Page | Next Page | Table of Contents | Index