git: 459511895e48 - main - cap_sysctl: expose structures and variables

Mariusz Zaborski oshogbo at FreeBSD.org
Mon Jan 4 19:57:41 UTC 2021


The branch main has been updated by oshogbo:

URL: https://cgit.FreeBSD.org/src/commit/?id=459511895e48e8f0a6673bd452812e994d96a960

commit 459511895e48e8f0a6673bd452812e994d96a960
Author:     Mariusz Zaborski <oshogbo at FreeBSD.org>
AuthorDate: 2021-01-04 19:56:07 +0000
Commit:     Mariusz Zaborski <oshogbo at FreeBSD.org>
CommitDate: 2021-01-04 19:56:07 +0000

    cap_sysctl: expose structures and variables
    
    Expose structures and variables that may be used on systems
    build without Casper support.
---
 lib/libcasper/services/cap_sysctl/cap_sysctl.h | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/lib/libcasper/services/cap_sysctl/cap_sysctl.h b/lib/libcasper/services/cap_sysctl/cap_sysctl.h
index df0fb7fd6f45..5a338d672a84 100644
--- a/lib/libcasper/services/cap_sysctl/cap_sysctl.h
+++ b/lib/libcasper/services/cap_sysctl/cap_sysctl.h
@@ -38,12 +38,16 @@
 
 #include <sys/cdefs.h>
 
-#ifdef WITH_CASPER
 #define	CAP_SYSCTL_READ		0x01
 #define	CAP_SYSCTL_WRITE	0x02
 #define	CAP_SYSCTL_RDWR		(CAP_SYSCTL_READ | CAP_SYSCTL_WRITE)
 #define	CAP_SYSCTL_RECURSIVE	0x04
 
+struct cap_sysctl_limit;
+typedef struct cap_sysctl_limit cap_sysctl_limit_t;
+
+#ifdef WITH_CASPER
+
 __BEGIN_DECLS
 
 int cap_sysctl(cap_channel_t *chan, const int *name, u_int namelen, void *oldp,
@@ -53,9 +57,6 @@ int cap_sysctlbyname(cap_channel_t *chan, const char *name, void *oldp,
 int cap_sysctlnametomib(cap_channel_t *chan, const char *name, int *mibp,
     size_t *sizep);
 
-struct cap_sysctl_limit;
-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);


More information about the dev-commits-src-all mailing list