cr_perror.3 (2010 09)

c
cr_perror(3) cr_perror(3)
NAME
cr_perror - print a libcrash error or warning message
SYNOPSIS
#include <libcrash.h>
void cr_perror(CRASH *crash_cb, int error);
DESCRIPTION
cr_perror() prints to standard error an error or warning message corresponding to error , which
should be the return value from an immediately previous call to one of the libcrash calls. The message
describes the problem that occurred, explains its implications when appropriate, and gives corrective
action where appropriate.
If called with a zero error value, indicating success,
cr_perror() prints nothing. Therefore, it can be
called after each libcrash call without harm. (If called after
cr_verify() with the CR_ERRORMSGS
flag set, repeated error messages may result.)
crash_cb should be the same crash dump descriptor as was passed to the call that returned error . If the
call was
cr_open(), pass the crash dump descriptor returned by that call, even if it is NULL.
If error is
CRERR_ERRNO, indicating that the system variable
errno contains the error information,
cr_perror() will refer to errno to print the appropriate message. In these cases it is critical that
cr_perror() be called immediately after the offending libcrash call returns.
AUTHOR
cr_perror () was developed by HP.
SEE ALSO
cr_open(3), cr_verify(3), libcrash(5).
HP-UX 11i Version 3: September 2010 1 Hewlett-Packard Company 1

Summary of content (2 pages)