- Note that these interfaces require <sys/user.h> for the structure
definitions. - Note that these functions return NULL on failure. MFC after: 3 days
This commit is contained in:
parent
c420fd5bb2
commit
6a3401c5dc
@ -35,6 +35,7 @@
|
|||||||
.Lb libutil
|
.Lb libutil
|
||||||
.Sh SYNOPSIS
|
.Sh SYNOPSIS
|
||||||
.In sys/types.h
|
.In sys/types.h
|
||||||
|
.In sys/user.h
|
||||||
.In libutil.h
|
.In libutil.h
|
||||||
.Ft struct kinfo_file *
|
.Ft struct kinfo_file *
|
||||||
.Fn kinfo_getfile "pid_t pid" "int *cntp"
|
.Fn kinfo_getfile "pid_t pid" "int *cntp"
|
||||||
@ -58,7 +59,7 @@ mib.
|
|||||||
While the kernel returns a packed structure, this function expands the
|
While the kernel returns a packed structure, this function expands the
|
||||||
data into a fixed record format.
|
data into a fixed record format.
|
||||||
.Sh RETURN VALUES
|
.Sh RETURN VALUES
|
||||||
The
|
On success the
|
||||||
.Fn kinfo_getfile
|
.Fn kinfo_getfile
|
||||||
function returns a pointer to an array of
|
function returns a pointer to an array of
|
||||||
.Vt struct kinfo_file
|
.Vt struct kinfo_file
|
||||||
@ -67,6 +68,10 @@ The array was obtained by an internal call to
|
|||||||
.Xr malloc 3
|
.Xr malloc 3
|
||||||
and must be freed by the caller with a call to
|
and must be freed by the caller with a call to
|
||||||
.Xr free 3 .
|
.Xr free 3 .
|
||||||
|
On failure the
|
||||||
|
.Fn kinfo_getfile
|
||||||
|
function returns
|
||||||
|
.Dv NULL .
|
||||||
.Sh SEE ALSO
|
.Sh SEE ALSO
|
||||||
.Xr free 3 ,
|
.Xr free 3 ,
|
||||||
.Xr kinfo_getvmmap 3 ,
|
.Xr kinfo_getvmmap 3 ,
|
||||||
|
@ -35,6 +35,7 @@
|
|||||||
.Lb libutil
|
.Lb libutil
|
||||||
.Sh SYNOPSIS
|
.Sh SYNOPSIS
|
||||||
.In sys/types.h
|
.In sys/types.h
|
||||||
|
.In sys/user.h
|
||||||
.In libutil.h
|
.In libutil.h
|
||||||
.Ft struct kinfo_vmentry *
|
.Ft struct kinfo_vmentry *
|
||||||
.Fn kinfo_getfile "pid_t pid" "int *cntp"
|
.Fn kinfo_getfile "pid_t pid" "int *cntp"
|
||||||
@ -58,7 +59,7 @@ mib.
|
|||||||
While the kernel returns a packed structure, this function expands the
|
While the kernel returns a packed structure, this function expands the
|
||||||
data into a fixed record format.
|
data into a fixed record format.
|
||||||
.Sh RETURN VALUES
|
.Sh RETURN VALUES
|
||||||
The
|
On success the
|
||||||
.Fn kinfo_getvmmap
|
.Fn kinfo_getvmmap
|
||||||
function returns a pointer to an array of
|
function returns a pointer to an array of
|
||||||
.Vt struct kinfo_vmentry
|
.Vt struct kinfo_vmentry
|
||||||
@ -67,6 +68,10 @@ The array was obtained by an internal call to
|
|||||||
.Xr malloc 3
|
.Xr malloc 3
|
||||||
and must be freed by the caller with a call to
|
and must be freed by the caller with a call to
|
||||||
.Xr free 3 .
|
.Xr free 3 .
|
||||||
|
On failure the
|
||||||
|
.Fn kinfo_getvmmap
|
||||||
|
function returns
|
||||||
|
.Dv NULL .
|
||||||
.Sh SEE ALSO
|
.Sh SEE ALSO
|
||||||
.Xr free 3 ,
|
.Xr free 3 ,
|
||||||
.Xr kinfo_getfile 3 ,
|
.Xr kinfo_getfile 3 ,
|
||||||
|
Loading…
Reference in New Issue
Block a user