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

48 Chapter4
HP C/iX Library Header Descriptions
Header File Contents
General Utilities <stdlib.h>
The header <stdlib.h> contains a number of general-purpose declarations and
definitions. It defines functions used for:
string data type conversion
multibyte character and string manipulation
memory management
array searching and sorting
integer arithmetic
communicating with the environment
The following identifiers are defined in <stdlib.h>:
vsprintf() function Writes formatted data to a character string in memory using
a variable argument list.
_IOFBF,
_IOLBF,
_IONBF
macro Constant expressions with values suitable for use as the
third argument to the setvbuf function.
_NFILE
d
macro Defines the maximum number of open files allowed per
process.
a. These identifiers are not defined by the ANSI C standard. Programs using these
identifiers are likely to be less portable.
b. These identifiers are not defined by the ANSI C standard. Programs using these
identifiers are likely to be less portable.
c. These identifiers are not defined by the ANSI C standard. Programs using these
identifiers are likely to be less portable.
d. These identifiers are not defined by the ANSI C standard. Programs using these
identifiers are likely to be less portable.
Table 4-14. General Utilities <stdlib.h>
Name Type Description
abort() function Terminates a program abnormally.
abs() function Computes the absolute value of an integer.
atexit() function Specifies a function to call when a program terminates.
atof() function Converts a string to a double floating-point value.
atoi() function Converts a string to an integer.
atol() function Converts a string to a long integer.
bsearch() function Performs a binary search of a sorted array.
Table 4-13. Input/Output <stdio.h>
Name Type Description