libprocstat.3 (249676) | libprocstat.3 (249677) |
---|---|
1.\" Copyright (c) 2011 Sergey Kandaurov <pluknet@FreeBSD.org> 2.\" All rights reserved. 3.\" 4.\" Redistribution and use in source and binary forms, with or without 5.\" modification, are permitted provided that the following conditions 6.\" are met: 7.\" 1. Redistributions of source code must retain the above copyright 8.\" notice, this list of conditions and the following disclaimer. --- 8 unchanged lines hidden (view full) --- 17.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 18.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 19.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 20.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 21.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 22.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 23.\" SUCH DAMAGE. 24.\" | 1.\" Copyright (c) 2011 Sergey Kandaurov <pluknet@FreeBSD.org> 2.\" All rights reserved. 3.\" 4.\" Redistribution and use in source and binary forms, with or without 5.\" modification, are permitted provided that the following conditions 6.\" are met: 7.\" 1. Redistributions of source code must retain the above copyright 8.\" notice, this list of conditions and the following disclaimer. --- 8 unchanged lines hidden (view full) --- 17.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 18.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 19.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 20.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 21.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 22.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 23.\" SUCH DAMAGE. 24.\" |
25.\" $FreeBSD: head/lib/libprocstat/libprocstat.3 249676 2013-04-20 08:02:43Z trociny $ | 25.\" $FreeBSD: head/lib/libprocstat/libprocstat.3 249677 2013-04-20 08:03:56Z trociny $ |
26.\" 27.Dd April 1, 2012 28.Dt LIBPROCSTAT 3 29.Os 30.Sh NAME 31.Nm procstat_open_core , 32.Nm procstat_open_kvm , 33.Nm procstat_open_sysctl , 34.Nm procstat_close , 35.Nm procstat_getfiles , 36.Nm procstat_getgroups , | 26.\" 27.Dd April 1, 2012 28.Dt LIBPROCSTAT 3 29.Os 30.Sh NAME 31.Nm procstat_open_core , 32.Nm procstat_open_kvm , 33.Nm procstat_open_sysctl , 34.Nm procstat_close , 35.Nm procstat_getfiles , 36.Nm procstat_getgroups , |
37.Nm procstat_getosrel , |
|
37.Nm procstat_getpathname , 38.Nm procstat_getprocs , 39.Nm procstat_getumask , 40.Nm procstat_getvmmap , 41.Nm procstat_freefiles , 42.Nm procstat_freegroups , 43.Nm procstat_freeprocs , 44.Nm procstat_freevmmap , --- 70 unchanged lines hidden (view full) --- 115.Fa "struct kinfo_proc *kp" 116.Fa "int mmapped" 117.Fc 118.Ft "gid_t *" 119.Fo procstat_getgroups 120.Fa "struct procstat *procstat" 121.Fa "struct kinfo_proc *kp" 122.Fa "unsigned int *count" | 38.Nm procstat_getpathname , 39.Nm procstat_getprocs , 40.Nm procstat_getumask , 41.Nm procstat_getvmmap , 42.Nm procstat_freefiles , 43.Nm procstat_freegroups , 44.Nm procstat_freeprocs , 45.Nm procstat_freevmmap , --- 70 unchanged lines hidden (view full) --- 116.Fa "struct kinfo_proc *kp" 117.Fa "int mmapped" 118.Fc 119.Ft "gid_t *" 120.Fo procstat_getgroups 121.Fa "struct procstat *procstat" 122.Fa "struct kinfo_proc *kp" 123.Fa "unsigned int *count" |
124.Ft int 125.Fo procstat_getosrel 126.Fa "struct procstat *procstat" 127.Fa "struct kinfo_proc *kp" 128.Fa "int *osrelp" |
|
123.Fc 124.Ft "struct kinfo_proc *" 125.Fo procstat_getprocs 126.Fa "struct procstat *procstat" 127.Fa "int what" 128.Fa "int arg" 129.Fa "unsigned int *count" 130.Fc --- 140 unchanged lines hidden (view full) --- 271structure, and returns the process groups as a dynamically allocated array of 272.Vt gid_t 273elements. 274The caller is responsible to free the allocated memory with a subsequent 275.Fn procstat_freegroups 276function call. 277.Pp 278The | 129.Fc 130.Ft "struct kinfo_proc *" 131.Fo procstat_getprocs 132.Fa "struct procstat *procstat" 133.Fa "int what" 134.Fa "int arg" 135.Fa "unsigned int *count" 136.Fc --- 140 unchanged lines hidden (view full) --- 277structure, and returns the process groups as a dynamically allocated array of 278.Vt gid_t 279elements. 280The caller is responsible to free the allocated memory with a subsequent 281.Fn procstat_freegroups 282function call. 283.Pp 284The |
285.Fn procstat_getosrel 286function gets a pointer to the 287.Vt procstat 288structure, a pointer to 289.Vt kinfo_proc 290structure, and returns osrel date in the 3rd reference parameter. 291.Pp 292The |
|
279.Fn procstat_getpathname 280function gets a pointer to the 281.Vt procstat 282structure, a pointer to 283.Vt kinfo_proc 284structure, and copies the path of the process executable to 285.Fa pathname 286buffer, limiting to --- 112 unchanged lines hidden --- | 293.Fn procstat_getpathname 294function gets a pointer to the 295.Vt procstat 296structure, a pointer to 297.Vt kinfo_proc 298structure, and copies the path of the process executable to 299.Fa pathname 300buffer, limiting to --- 112 unchanged lines hidden --- |