16096 want proc_get_lwpstatus(3PROC)
[illumos-gate.git] / usr / src / man / man3proc / proc_str2fltset.3proc
blobbb3a7bcc35c77f4a1719ec0f8ee122f199f9efba
1 .\"
2 .\" This file and its contents are supplied under the terms of the
3 .\" Common Development and Distribution License ("CDDL"), version 1.0.
4 .\" You may only use this file in accordance with the terms of version
5 .\" 1.0 of the CDDL.
6 .\"
7 .\" A full copy of the text of the CDDL should have accompanied this
8 .\" source.  A copy of the CDDL is also available via the Internet at
9 .\" http://www.illumos.org/license/CDDL.
10 .\"
11 .\"
12 .\" Copyright 2015 Joyent, Inc.
13 .\"
14 .Dd November 27, 2023
15 .Dt PROC_STR2FLTSET 3PROC
16 .Os
17 .Sh NAME
18 .Nm proc_str2fltset ,
19 .Nm proc_str2sigset ,
20 .Nm proc_str2sysset
21 .Nd convert a string to a fault, signal, or system call set
22 .Sh LIBRARY
23 .Lb libproc
24 .Sh SYNOPSIS
25 .In libproc.h
26 .Ft char *
27 .Fo proc_str2fltset
28 .Fa "const char *str"
29 .Fa "const char *delim"
30 .Fa "int members"
31 .Fa "fltset_t *set"
32 .Fc
33 .Ft char *
34 .Fo proc_str2sigset
35 .Fa "const char *str"
36 .Fa "const char *delim"
37 .Fa "int members"
38 .Fa "sigset_t *set"
39 .Fc
40 .Ft char *
41 .Fo proc_str2sysset
42 .Fa "const char *str"
43 .Fa "const char *delim"
44 .Fa "int members"
45 .Fa "sysset_t *set"
46 .Fc
47 .Sh DESCRIPTION
48 The
49 .Fn proc_str2fltset ,
50 .Fn proc_str2sigset ,
51 and
52 .Fn proc_str2sysset
53 functions translate a character string,
54 .Fa str ,
55 into the corresponding fault set, signal set, and system call set
56 respectively.
57 .Pp
58 The character string
59 .Fa delim
60 will be used as a delimiter between subsequent entries in the string
61 .Fa set .
62 The value of
63 .Fa members
64 determines whether the entries in
65 .Fa str
66 enable or disable entries in
67 .Fa set .
69 .Fa members
70 is zero, then
71 .Fa set
72 is filled in entirely and then each entry in
73 .Fa str
74 causes the corresponding entry to be disabled in
75 .Fa set.
77 .Fa members
78 is non-zero, then
79 .Fa set
80 is empty initially and for each entry in
81 .Fa str
82 the corresponding entry in
83 .Fa set
84 will be enabled.
85 .Pp
86 If an unknown entry is encountered in
87 .Fa str
88 then the conversion will fail and a pointer to the first unknown
89 character will be returned.
90 .Sh RETURN VALUES
91 Upon successful completion,
92 .Dv NULL
93 is returned and
94 .Fa set
95 is filled in.
96 Otherwise, a pointer to the first unknown character is returned and
97 .Sy errno
98 is set to indicate the error.
99 .Sh ERRORS
101 .Fn proc_str2fltset ,
102 .Fn proc_str2sigset ,
104 .Fn proc_str2sigset
105 functions will fail if:
106 .Bl -tag -width Er
107 .It Er EINVAL
108 .Fa str
109 contains an unrecognized set name.
111 .Sh INTERFACE STABILITY
112 .Sy Uncommitted
113 .Sh MT-LEVEL
114 .Sy MT-Safe
115 .Sh SEE ALSO
116 .Xr libproc 3LIB ,
117 .Xr proc_fltname 3PROC ,
118 .Xr proc_fltset2str 3PROC ,
119 .Xr proc_signame 3PROC ,
120 .Xr proc_sigset2str 3PROC ,
121 .Xr proc_str2flt 3PROC ,
122 .Xr proc_str2sig 3PROC ,
123 .Xr proc_str2sys 3PROC ,
124 .Xr proc_sysname 3PROC ,
125 .Xr proc_sysset2str 3PROC ,
126 .Xr proc 5