Wording improvements

This commit is contained in:
Michael Kerrisk 2005-06-14 11:22:06 +00:00
parent 7b57506d6d
commit 5af3e8eeee
1 changed files with 7 additions and 6 deletions

View File

@ -30,7 +30,7 @@
.\"
.TH ATEXIT 3 2003-11-01 "" "Linux Programmer's Manual"
.SH NAME
atexit \- register a function to be called at normal program termination
atexit \- register a function to be called at normal process termination
.SH SYNOPSIS
.nf
.B #include <stdlib.h>
@ -39,18 +39,19 @@ atexit \- register a function to be called at normal program termination
.fi
.SH DESCRIPTION
The \fBatexit()\fP function registers the given \fIfunction\fP to be
called at normal program termination, either via
called at normal process termination, either via
.BR exit (3)
or via return from the program's \fBmain\fP().
Functions so registered are called in
the reverse order of their registration; no arguments are passed.
.LP
At least ATEXIT_MAX functions can be registered. This value
is at least 32. It can be obtained using
POSIX.1 requires that an implementation allow at least ATEXIT_MAX (32)
process termination functions to be registered.
The actual limit supported by an implementation can be obtained using
.BR sysconf (3).
.LP
By a successful call to one of the exec functions,
all registrations are undone.
Upon a successful call to one of the exec functions,
the registrations of all process termination functions are removed.
.SH "RETURN VALUE"
The \fBatexit()\fP function returns the value 0 if successful; otherwise
it returns a nonzero value.