Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

kill (nr 62)

Send a signal to a process.

Signature

kill(pid: pid_t, sig: int) → 0 or -errno

Arguments

ArgRegisterDescription
pidrdiTarget process ID
sigrsiSignal number (1–31)

Return value

Returns 0 on success.

Errors

ErrorCondition
EINVALSignal number is out of range (< 1 or > 31)
ESRCHNo process with the given PID exists

Description

Queues the specified signal on the target process. The signal is delivered before the process next returns to user space (checked after syscalls and interrupts).

Currently only supports sending to a specific PID. Negative PIDs (process groups) and PID 0 (current process group) are not yet supported.

Implementation

osl/src/signal.rssys_kill

See also