PCLEARFAULT(3PROC) Process Control Library Functions PCLEARFAULT(3PROC)

Pclearfault, Lclearfaultclear process and thread faults

Process Control Library (libproc, -lproc)

#include <libproc.h>

int
Pclearfault(struct ps_prochandle *P);

int
Lclearfault(struct ps_lwphandle *L);

During normal operation a process may encounter a , due to a hardware exception, identifying a problem with the running process. Hardware faults include things like executing illegal instructions, encountering a breakpoint, and arithmetic exceptions. Faults are discussed further in proc(5).

The () function instructs the system to clear any fault pending delivery to a thread in the process represented by the process handle P. The pending fault will never be delivered to process represented by P.

The () function is identical to the Pclearfault() function, except rather than operating on the representative thread of the process it operates on the thread handle L.

The () and Lclearfault() functions only have meaning for active processes. They will fail on process handles corresponding to zombie processes, ELF objects, and cores.

Upon successful completion, the Pclearfault() and Lclearfault() functions clear pending faults and return . Otherwise, is returned, is set to indicate the error, and no faults are cleared.

For a full list of possible errors see the section in proc(5).

See in libproc(3LIB).

libproc(3LIB), proc(5)

May 11, 2016 OmniOS