Chapter Contents |
Previous |
Next |
SIGABRT |
Default handling | |
Ignoring the signal | |
Information returned by siginfo | |
USS considerations |
SIGABRT
signal is raised when the
abort
function
is called or when a user ABEND occurs.
SIGABRT
may not be raised for an ABEND issued by the SAS/C library, depending
on the severity of the problem.
Default handling |
By default,
SIGABRT
causes abnormal program termination. If
SIGABRT
results from a call to
abort
or
raise
, the program is terminated with
user ABEND code 1210. If
SIGABRT
results
from a call to
siggen
, the ABEND code is
taken from the
ABRT_t
structure passed
to
siggen
.
Ignoring the signal |
The
SIGABRT
signal cannot be ignored. Similarly, a handler for
SIGABRT
cannot return to the point of interrupt; an attempt to do
so
causes ABEND to be reissued.
Information returned by siginfo |
If you call
siginfo
after a
SIGABRT
signal occurs,
siginfo
returns a pointer to a structure of type
ABRT_t
. This structure is
defined as:
typedef struct { unsigned ABEND_code; /* ABEND code */ char *ABEND_str; /* formatted ABEND code, */ /* e.g., "B14", "U0240", */ void *ABEND_info; /* OS SDWA, or CMS ABWSECT */ } ABRT_t;
The
ABEND_code
is
an integer from 0 through 4095 giving the ABEND code. The
ABEND_str
is a null-terminated string giving a printable form of the
ABEND code.
The
ABEND_info
pointer
addresses an ABEND status block provided by the operating system, which gives
the ABEND PSW, registers, and other such information. Under OS/390,
ABEND_str
addresses an SDWA. Under CMS, it addresses
an ABWSECT. For an ABEND issued by the SAS/C library,
ABEND_info
may be
NULL
.
USS considerations |
SAS/C uses
SIGABRT
to signal a user ABEND, including a library ABEND. This differs
from USS, which expects every ABEND to be signaled by
SIGABND
.
Chapter Contents |
Previous |
Next |
Top of Page |
Copyright © 2001 by SAS Institute Inc., Cary, NC, USA. All rights reserved.