Print this page
8158 Want named threads API
9857 proc manpages should have LIBRARY section
Split |
Close |
Expand all |
Collapse all |
--- old/usr/src/man/man3proc/Penv_iter.3proc.man.txt
+++ new/usr/src/man/man3proc/Penv_iter.3proc.man.txt
1 1 PENV_ITER(3PROC) Process Control Library Functions PENV_ITER(3PROC)
2 2
3 3 NAME
4 4 Penv_iter - iterate process environment
5 5
6 -SYNOPSIS
6 +LIBRARY
7 7 Process Control Library (libproc, -lproc)
8 +
9 +SYNOPSIS
8 10 #include <libproc.h>
9 11
10 12 int
11 13 Penv_iter(struct ps_prochandle *P, proc_env_f *func, void *data);
12 14
13 15 DESCRIPTION
14 16 The Penv_iter() function iterates over the environment of the process
15 17 represented by P. For each environment variable, func is passed the
16 18 caller argument data along with the address of the environment variable
17 19 and the key-value pair. For the full signature of the proc_env_f
18 20 callback, see libproc(3LIB).
19 21
20 22 The callback's return value controls whether or not iteration proceeds.
21 23 If func returns zero, then iteration continues. Otherwise, iteration is
22 24 terminated and the value is returned. It is recommended that callback
23 25 functions do not return -1 so as to distinguish between the failure of
24 26 the Penv_iter() function and the callback function.
25 27
26 28 RETURN VALUES
27 29 Upon successful completion, the Penv_iter() function returns 0.
28 30 Otherwise, if there was an internal error, for example due to a corrupted
29 31 environment, then -1 is returned. Otherwise, if the callback function
30 32 func returns non-zero, then its return value will be returned instead.
31 33
32 34 INTERFACE STABILITY
33 35 Uncommitted
34 36
35 37 MT-LEVEL
36 38 See LOCKING in libproc(3LIB).
37 39
38 40 SEE ALSO
39 41 libproc(3LIB)
40 42
41 43 illumos March 2, 2017 illumos
↓ open down ↓ |
24 lines elided |
↑ open up ↑ |
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX