---
name: "sysdecode_sigcode"
section: "3"
platform: "freebsd"
package: "base"
version: "16.0-CURRENT-20261027-61c70dc16a79"
release: "FreeBSD 16.0-CURRENT (2026-10-27)"
platforms: ["freebsd"]
url: "https://new.carta.tech/sysdecode_sigcode"
---

# sysdecode\_sigcode(3)

lookup name of signal code

## NAME

**sysdecode\_sigcode** – lookup name of signal code

## LIBRARY

library “libsysdecode”

## SYNOPSIS

**#include \<sysdecode.h\>**

*const* *char* *\**\

**sysdecode\_sigcode**(*int signal*, *int si\_code*);

## DESCRIPTION

The **sysdecode\_sigcode**() function returns a text description of the *si\_code* field of the *siginfo\_t* object associated with an instance of signal *sig*. The text description contains the name of the C macro whose value matches *si\_code*. General purpose signal codes such as SI\_USER are handled as well as signal-specific codes for SIGBUS, SIGCHLD, SIGFPE, SIGILL, SIGSEGV and SIGTRAP. If *si\_code* does not represent a known signal code, **sysdecode\_sigcode**() returns NULL.

## RETURN VALUES

The **sysdecode\_sigcode**() function returns a pointer to a signal code description or NULL if *si\_code* is not a known signal code.

## SEE ALSO

[sysdecode\_sigbus\_code(3)](/sysdecode_sigbus_code/3.md), [sysdecode\_sigchld\_code(3)](/sysdecode_sigchld_code/3.md), [sysdecode\_sigfpe\_code(3)](/sysdecode_sigfpe_code/3.md), [sysdecode\_sigill\_code(3)](/sysdecode_sigill_code/3.md), [sysdecode\_sigsegv\_code(3)](/sysdecode_sigsegv_code/3.md), [sysdecode\_sigtrap\_code(3)](/sysdecode_sigtrap_code/3.md)
