143051d27SRobert Mustacchi.\" 243051d27SRobert Mustacchi.\" This file and its contents are supplied under the terms of the 343051d27SRobert Mustacchi.\" Common Development and Distribution License ("CDDL"), version 1.0. 443051d27SRobert Mustacchi.\" You may only use this file in accordance with the terms of version 543051d27SRobert Mustacchi.\" 1.0 of the CDDL. 643051d27SRobert Mustacchi.\" 743051d27SRobert Mustacchi.\" A full copy of the text of the CDDL should have accompanied this 843051d27SRobert Mustacchi.\" source. A copy of the CDDL is also available via the Internet at 943051d27SRobert Mustacchi.\" http://www.illumos.org/license/CDDL. 1043051d27SRobert Mustacchi.\" 1143051d27SRobert Mustacchi.\" 1243051d27SRobert Mustacchi.\" Copyright 2015 Joyent, Inc. 1343051d27SRobert Mustacchi.\" 1443051d27SRobert Mustacchi.Dd May 11, 2016 1543051d27SRobert Mustacchi.Dt PCLEARSIG 3PROC 1643051d27SRobert Mustacchi.Os 1743051d27SRobert Mustacchi.Sh NAME 1843051d27SRobert Mustacchi.Nm Pclearsig , 1943051d27SRobert Mustacchi.Nm Lclearsig 2043051d27SRobert Mustacchi.Nd clear process signals 2143051d27SRobert Mustacchi.Sh SYNOPSIS 2243051d27SRobert Mustacchi.Lb libproc 2343051d27SRobert Mustacchi.In libproc.h 2443051d27SRobert Mustacchi.Ft int 2543051d27SRobert Mustacchi.Fo Pclearsig 2643051d27SRobert Mustacchi.Fa "struct ps_prochandle *P" 2743051d27SRobert Mustacchi.Fc 2843051d27SRobert Mustacchi.Ft int 2943051d27SRobert Mustacchi.Fo Lclearsig 3043051d27SRobert Mustacchi.Fa "struct ps_lwphandle *L" 3143051d27SRobert Mustacchi.Fc 3243051d27SRobert Mustacchi.Sh DESCRIPTION 33*72d3dbb9SYuri PankovDuring normal operation a process may receive a signal. 34*72d3dbb9SYuri PankovSignals may indicate an error, for example referencing unmapped memory, an alarm 3543051d27SRobert Mustacchifiring, requests for information, and users requesting an interruption. 3643051d27SRobert MustacchiFor more information on the generation and usage of signals, see 3743051d27SRobert Mustacchi.Xr signal.h 3HEAD . 3843051d27SRobert Mustacchi.Pp 3943051d27SRobert MustacchiThe 4043051d27SRobert Mustacchi.Fn Pclearsig 4143051d27SRobert Mustacchifunction instructs the system to clear any signal pending delivery to 4243051d27SRobert Mustacchia thread in the process represented by the process handle 4343051d27SRobert Mustacchi.Fa P . 4443051d27SRobert MustacchiThe pending signal will never be delivered to process represented by 4543051d27SRobert Mustacchi.Fa P . 4643051d27SRobert Mustacchi.Pp 4743051d27SRobert MustacchiThe 4843051d27SRobert Mustacchi.Fn Lclearsig 4943051d27SRobert Mustacchifunction is identical to the 5043051d27SRobert Mustacchi.Fn Pclearsig 5143051d27SRobert Mustacchifunction, except rather than operating on the process and its 5243051d27SRobert Mustacchirepresentive thread, it instead operates on the thread handle 5343051d27SRobert Mustacchi.Fa L . 5443051d27SRobert Mustacchi.Pp 5543051d27SRobert MustacchiThe 5643051d27SRobert Mustacchi.Fn Pclearsig 57*72d3dbb9SYuri Pankovfunction only has meaning for active processes. 58*72d3dbb9SYuri PankovIt will fail on process handles corresponding to core files, zombie processes 59*72d3dbb9SYuri Pankovand ELF objects. 6043051d27SRobert Mustacchi.Sh RETURN VALUES 6143051d27SRobert MustacchiUpon successful completion, the 6243051d27SRobert Mustacchi.Fn Pclearsig 6343051d27SRobert Mustacchifunction clears pending faults and 6443051d27SRobert Mustacchireturns 6543051d27SRobert Mustacchi.Sy 0 . 6643051d27SRobert MustacchiOtherwise, 6743051d27SRobert Mustacchi.Sy -1 6843051d27SRobert Mustacchiis returned, 6943051d27SRobert Mustacchi.Sy errno 7043051d27SRobert Mustacchiis set to indicate the error, 7143051d27SRobert Mustacchiand no faults are cleared. 7243051d27SRobert Mustacchi.Sh ERRORS 7343051d27SRobert MustacchiFor a full list of possible errors see the 7443051d27SRobert Mustacchi.Sy DIAGNOSTICS 7543051d27SRobert Mustacchisection in 7643051d27SRobert Mustacchi.Xr proc 4 . 7743051d27SRobert Mustacchi.Sh INTERFACE STABILITY 7843051d27SRobert Mustacchi.Sy Uncommitted 7943051d27SRobert Mustacchi.Sh MT-LEVEL 8043051d27SRobert MustacchiSee 8143051d27SRobert Mustacchi.Sy LOCKING 8243051d27SRobert Mustacchiin 8343051d27SRobert Mustacchi.Xr libproc 3LIB . 8443051d27SRobert Mustacchi.Sh SEE ALSO 8543051d27SRobert Mustacchi.Xr signal.h 3HEAD , 8643051d27SRobert Mustacchi.Xr libproc 3LIB , 8743051d27SRobert Mustacchi.Xr proc 4 88