sysexits.h, but in a (sometimes) more accessible place. Formatted painlessly in Vim
style(9), it is not a good practice to call
exit(3) with arbitrary values to indicate a failure condition when ending a program. Instead, the pre-defined exit codes from
sysexits should be used, so the caller of the process can get a rough estimation about the failure class without looking up the source code.
The successful exit is always indicated by a status of
EX_OK. Error numbers begin at
EX__BASE to reduce the possibility of clashing with other exit statuses that random programs may already return. The meaning of the codes is approximately as follows: