HP C/iX Library Reference Manual (30026-90004)

Chapter 4 49
HP C/iX Library Header Descriptions
Header File Contents
calloc() function Allocates a block of memory.
div() function Computes the quotient and remainder of two integers.
div_t type definition A data type definition used when declaring the return value
for div().
exit() function Terminates the calling process normally.
EXIT_FAILURE macro A value that can be passed to the exit function to indicate
unsuccessful program termination.
EXIT_SUCCESS macro A value that can be passed to the exit function to indicate
successful program termination.
free() function Frees a block of allocated memory.
getenv() function Returns the value of an environment variable.
labs() function Computes the absolute value of a long integer.
ldiv() function Computes the quotient and remainder of two long integers.
ldiv_t type definition A data type definition used when declaring the return value
for ldiv().
malloc() function Allocates a block of memory.
mblen() function Determines the number of characters in a multibyte
character.
mbstowcs() function Converts a sequence of multibyte characters in a
null-terminated string to a sequence of wide character codes.
mbtowc() function Converts a single multibyte character to its wide character
representation.
MB_CUR_MAX macro Maximum size in bytes of a multibyte character.
NULL macro The constant 0.
qsort() function Sorts an array of objects.
rand() function Returns a random number.
RAND_MAX macro The maximum value returned by the rand function.
realloc() function Changes the size of a block of allocated memory.
size_t type definition The unsigned integral type of the sizeof operator.
srand() function Sets a starting point for calls to the rand function.
strtod() function Converts a string to a double-precision, floating-point number.
strtol() function Converts a string to a long integer value.
Table 4-14. General Utilities <stdlib.h>
Name Type Description