libcasper: Constify cap_sysctl_limit_mib() mib parameter
No functional change. Minor API change that is nicer for consumers. ABI is identical; the routine never needed to modify the pointed to value. Reviewed by: emaste, markj Differential Revision: https://reviews.freebsd.org/D24319
This commit is contained in:
parent
24891abdb2
commit
2750f1b954
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=359674
@ -24,7 +24,7 @@
|
||||
.\"
|
||||
.\" $FreeBSD$
|
||||
.\"
|
||||
.Dd May 13, 2019
|
||||
.Dd April 6, 2020
|
||||
.Dt CAP_SYSCTL 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
@ -46,7 +46,7 @@
|
||||
.Ft void *
|
||||
.Fn cap_sysctl_limit_name "void *limit" "const char *name" "int flags"
|
||||
.Ft void *
|
||||
.Fn cap_sysctl_limit_mib "void *limit" "int *mibp" "u_int miblen" "int flags"
|
||||
.Fn cap_sysctl_limit_mib "void *limit" "const int *mibp" "u_int miblen" "int flags"
|
||||
.Ft int
|
||||
.Fn cap_sysctl_limit "void *limit"
|
||||
.Sh DESCRIPTION
|
||||
|
@ -109,7 +109,7 @@ cap_sysctl_limit_name(cap_sysctl_limit_t *limit, const char *name, int flags)
|
||||
}
|
||||
|
||||
cap_sysctl_limit_t *
|
||||
cap_sysctl_limit_mib(cap_sysctl_limit_t *limit, int *mibp, u_int miblen,
|
||||
cap_sysctl_limit_mib(cap_sysctl_limit_t *limit, const int *mibp, u_int miblen,
|
||||
int flags)
|
||||
{
|
||||
nvlist_t *lnv;
|
||||
|
@ -55,8 +55,8 @@ typedef struct cap_sysctl_limit cap_sysctl_limit_t;
|
||||
cap_sysctl_limit_t *cap_sysctl_limit_init(cap_channel_t *);
|
||||
cap_sysctl_limit_t *cap_sysctl_limit_name(cap_sysctl_limit_t *limit,
|
||||
const char *name, int flags);
|
||||
cap_sysctl_limit_t *cap_sysctl_limit_mib(cap_sysctl_limit_t *limit, int *mibp,
|
||||
u_int miblen, int flags);
|
||||
cap_sysctl_limit_t *cap_sysctl_limit_mib(cap_sysctl_limit_t *limit,
|
||||
const int *mibp, u_int miblen, int flags);
|
||||
int cap_sysctl_limit(cap_sysctl_limit_t *limit);
|
||||
#else /* !WITH_CASPER */
|
||||
#define cap_sysctl(chan, name, namelen, oldp, oldlenp, newp, newlen) \
|
||||
|
Loading…
Reference in New Issue
Block a user