|PROC_ARG_PSINFO(3PROC)||Process Control Library Functions||PROC_ARG_PSINFO(3PROC)|
proc_arg_xpsinfo — process
ps information utility function
Process Control Library (libproc, -lproc)
proc_arg_psinfo(const char *arg,
int oflag, psinfo_t *psp,
*arg, int oflag, psinfo_t
*psp, int *perr, const char
functions are utility functions which process an argument that may refer to
a currently active process or core file and attempts to obtain the
ps(1) information from the process or core
and fills it into psp.
The string arg contains the name of something to try and open. How it is interpreted depends on the value of oflag. The following values may be passed in as a bitwise-exclusive-OR for oflag:
If the lwps argument is
NULL, then if there is a thread specification
present in arg, it will be validated to see if it is a
valid range and then a pointer to the start of the thread specification will
be stored in lwps. For more information on determining
process range validity, see
for more information on valid and invalid tread specifications.
Upon successful completion, the
proc_arg_xpsinfo() functions return the process
identifier and fill in psp with the ps information of
the process. Otherwise,
-1 is returned
and perr is filled in with the error's details.
For a full list of additional errors, see the ERRORS section in Pgrab_core(3PROC).
PR_ARG_CORESwas set and no core file could be found corresponding to arg.
PR_ARG_PIDSwas set and no process could be found corresponding to arg.
PR_ARG_NOPROCwere set and no process or core file could be found corresponding to arg.
|May 11, 2016||OmniOS|