Content-type: text/html Man page of siginfo

siginfo

Section: File Formats (5)
Index Return to Main Contents
 

NAME

siginfo - Details of signal generation  

SYNOPSIS

#include <siginfo.h>


 

DESCRIPTION

The siginfo structure provides processes with information on why a signal was generated, or a process that is monitoring child processes may receive information that specifies why a child process changed state. See the sigaction(2) and waitid(2) reference pages for more information.

The type siginfo_t contains the following members: Contains the system generated signal number. Note that for the waitid function, this field is always SIGCHLD. Contains, if non-zero, the errno that is associated with the signal. Specifies a code that determines whether the signal was generated by a user process, a specific signal, or by the kernel. When the value of si_code is less than or equal to zero (0), the signal was generated by a user process and the siginfo structure contains the following additional members:

pid_t si_pid /*sending process ID*/ uid_t si_uid /*sending user ID*/
See the kill(2) and sigsend(2) reference pages for more information on these fields.
The following table describes the meaning of the code generated by a signal. The table lists signals in alphabetical order.

SignalCodeDefinition

SIGBUSBUS_ADRALNinvalid address alignment
BUS_ADRERRnon-existent physical address
BUS_OBJERRobject specific hardware error
SIGCHLDCLD_EXITEDchild has exited
CLD_KILLEDchild was killed
CLD_DUMPEDchild terminated abnormally
CLD_TRAPPEDtraced child has trapped
CLD_STOPPEDchild has stopped
CLD_CONTINUEDstopped child has continued
CLD_SIGEXITING child is about to exit because it received a fatal signal
SIGILLILL_ILLOPCillegal opcode
ILL_ILLOPNillegal operand
ILL_ILLADRillegal addressing mode
ILL_ILLTRPillegal trap
ILL_PRVOPCprivileged opcode
ILL_PRVREGprivileged register
ILL_COPROCcoprocessor error
ILL_BADSTKinternal stack error
SIGFPEFPE_INTDIVinteger divide by zero
FPE_INTOVFinteger overflow
FPE_FLTDIVfloating point divide by zero
FPE_FLTOVFfloating point overflow
FPE_FLTUNDfloating point underflow
FPE_FLTRESfloating point inexact result
FPE_FLTINV invalid floating point operation
FPE_FLTSUBsubscript out of range
SIGPOLLPOLL_INdata input available
POLL_OUToutput buffers available
POLL_MSGinput message available
POLL_ERRI/O error
POLL_PRIhigh priority input available
POLL_HUPdevice disconnected
SIGSEGVSEGV_MAPERRaddress not mapped to object
SEGV_ACCERR invalid permissions for mapped object
SIGTRAPTRAP_BRKPTprocess breakpoint
TRAP_TRACEprocess trace trap

When a signal is generated by the system, the meaning of the code is as follows:

SignalFieldDescription

SIGILLcaddr_t si_addraddress of faulting instruction
SIGFPE
SIGSEGVcaddr_t si_addraddress of faulting memory
SIGBUSreference
SIGCHLDpid_t si_pidchild process ID
int si_statusexit value or signal
SIGPOLLlong si_bandband event for POLL_IN,
POLL_OUT, or POLL_MSG

Note, if the signal is SIGCHLD, and the si_code is equivalent to CLD_EXITED, si_status is equivalent to the exit value of the process. If si_code is not equivalent to CLD_EXITED, the si_status field is equivalent to the signal that caused the process to change state. In some instances, si_addr may not be defined, but si_addr will appear on the same page as the faulting instruction or memory reference.
 

SEE ALSO

Functions: kill(2), sigaction(2), sigsend(2), waitid(2)

Files: signal(4)


 

Index

NAME
SYNOPSIS
DESCRIPTION
SEE ALSO

This document was created by man2html, using the manual pages.
Time: 02:43:08 GMT, October 02, 2010