diff options
author | trociny <trociny@FreeBSD.org> | 2013-04-20 07:54:07 +0000 |
---|---|---|
committer | trociny <trociny@FreeBSD.org> | 2013-04-20 07:54:07 +0000 |
commit | 1597072d3810fd47b494e26cbcaa815406288b8a (patch) | |
tree | 0aef80ff5d92444d56c16b7f1f3a73a8de076b33 /lib/libprocstat/libprocstat.3 | |
parent | 52df6246c7718931beb8fcc43b4ebb5fd64ccd6e (diff) | |
download | FreeBSD-src-1597072d3810fd47b494e26cbcaa815406288b8a.zip FreeBSD-src-1597072d3810fd47b494e26cbcaa815406288b8a.tar.gz |
Add procstat_getgroups function to retrieve process groups.
MFC after: 1 month
Diffstat (limited to 'lib/libprocstat/libprocstat.3')
-rw-r--r-- | lib/libprocstat/libprocstat.3 | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/lib/libprocstat/libprocstat.3 b/lib/libprocstat/libprocstat.3 index 18dc1e9..b38ce1c 100644 --- a/lib/libprocstat/libprocstat.3 +++ b/lib/libprocstat/libprocstat.3 @@ -33,9 +33,11 @@ .Nm procstat_open_sysctl , .Nm procstat_close , .Nm procstat_getfiles , +.Nm procstat_getgroups , .Nm procstat_getprocs , .Nm procstat_getvmmap , .Nm procstat_freefiles , +.Nm procstat_freegroups , .Nm procstat_freeprocs , .Nm procstat_freevmmap , .Nm procstat_get_pipe_info , @@ -52,12 +54,18 @@ .In libprocstat.h .Ft void .Fn procstat_close "struct procstat *procstat" +.Fc .Ft void .Fo procstat_freefiles .Fa "struct procstat *procstat" .Fa "struct filestat_list *head" .Fc .Ft void +.Fo procstat_freegroups +.Fa "struct procstat *procstat" +.Fa "gid_t *groups" +.Fc +.Ft void .Fn procstat_freeprocs "struct procstat *procstat" "struct kinfo_proc *p" .Ft void .Fo procstat_freevmmap @@ -105,6 +113,12 @@ .Fa "struct kinfo_proc *kp" .Fa "int mmapped" .Fc +.Ft "gid_t *" +.Fo procstat_getgroups +.Fa "struct procstat *procstat" +.Fa "struct kinfo_proc *kp" +.Fa "unsigned int *count" +.Fc .Ft "struct kinfo_proc *" .Fo procstat_getprocs .Fa "struct procstat *procstat" @@ -227,6 +241,19 @@ The caller is responsible to free the allocated memory with a subsequent function call. .Pp The +.Fn procstat_getgroups +function gets a pointer to the +.Vt procstat +structure, a pointer to +.Vt kinfo_proc +structure, and returns the process groups as a dynamically allocated array of +.Vt gid_t +elements. +The caller is responsible to free the allocated memory with a subsequent +.Fn procstat_freegroups +function call. +.Pp +The .Fn procstat_getvmmap function gets a pointer to the .Vt procstat |