.ig Copyright (C) 1993,1994 by the author(s). This software is published in the hope that it will be useful, but WITHOUT ANY WARRANTY for any part of this software to work correctly or as described in the manuals. See the ShapeTools Public License for details. Permission is granted to use, copy, modify, or distribute any part of this software but only under the conditions described in the ShapeTools Public License. A copy of this license is supposed to have been given to you along with ShapeTools in a file named LICENSE. Among other things, this copyright notice and the Public License must be preserved on all copies. Author: Andreas Lampen (Andreas.Lampen@cs.tu-berlin.de) $Header: af_error.3[7.0] Fri Jun 25 14:33:06 1993 andy@cs.tu-berlin.de frozen $ .. .TH af_error 3 "Fri Jun 25 14:33:06 1993" "AtFS-1.71" "Attribute Filesystem (AtFS)" .SH NAME af_errno, af_perror, af_errmsg, af_cleanup \- AtFS error handling .SH SYNOPSIS #include .sp .ta 1.2c int af_errno .sp void af_perror (char *string) .sp char* af_errmsg (char *string) .sp int af_cleanup (void) .sp .SH DESCRIPTION \fIaf_errno\fP is the global AtFS error number variable. If an AtFS functions returns with an error, \fIaf_errno\fP is set to indicate the appropriate error number. It is not cleared upon successful calls. The af_intro(3) manual page gives an overview of all error codes. .LP \fIaf_perror\fP produces a short error message of the form described in perror(3). This message will be written to standard error. If the last error encountered during an AtFS application was an AtFS\-specific error, a corresponding message is generated, otherwise af_perror calls perror(3). .LP \fIaf_errmsg\fP does the same as af_perror but returns the message rather than writing to standard error. The result string resides in static memory and hence will be overwritten on subsequent calls of af_errmsg. .LP \fIAf_cleanup\fP serves as cleanup routine upon premature termination of an AtFS application. It removes temporary files and frees all allocated memory. .SH SEE ALSO intro(2), af_intro(3), perror(3)