diff options
author | 2015-10-09 01:24:57 +0000 | |
---|---|---|
committer | 2015-10-09 01:24:57 +0000 | |
commit | 4c738cc8dfcda4dd9f8b01ab736a275a5eeb36f7 (patch) | |
tree | 15710f9fa802033a946ecacf92f5b02423e41939 /lib/libc/sys/tame.c | |
parent | Rename tame() to pledge(). This fairly interface has evolved to be more (diff) | |
download | wireguard-openbsd-4c738cc8dfcda4dd9f8b01ab736a275a5eeb36f7.tar.xz wireguard-openbsd-4c738cc8dfcda4dd9f8b01ab736a275a5eeb36f7.zip |
tame -> pledge conversion, in libc. I should crank libc, but am cheating
hoping things go well. The old symbol is faked via a stupid stub function,
until next major crank when it can be removed. I am expecting guenther
to scream at me.
Diffstat (limited to 'lib/libc/sys/tame.c')
-rw-r--r-- | lib/libc/sys/tame.c | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/lib/libc/sys/tame.c b/lib/libc/sys/tame.c new file mode 100644 index 00000000000..4774a17afeb --- /dev/null +++ b/lib/libc/sys/tame.c @@ -0,0 +1,17 @@ +/* $OpenBSD: tame.c,v 1.1 2015/10/09 01:24:57 deraadt Exp $ */ +/* + * Written by Artur Grabowski <art@openbsd.org> Public Domain + */ + +#include <sys/types.h> +#include <sys/syscall.h> +#include <unistd.h> + +int tame(const char *req, const char **paths); + +int +tame(const char *req, const char **paths) +{ + return (pledge(req, paths)); +} +DEF_WEAK(mquery); |