summaryrefslogtreecommitdiff
path: root/sys/kern
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>2015-10-10 14:48:04 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>2015-10-10 14:48:04 +0000
commitd10c958965bcf1ca39b219baaa5b29e74b7e7878 (patch)
tree4fa39520b436ae88e14e20e23503d0b67555edfb /sys/kern
parent051fad188a4075c3492c0f1c8366c01e8fb5d323 (diff)
allow sysctl of kern.clockrate
Diffstat (limited to 'sys/kern')
-rw-r--r--sys/kern/kern_pledge.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/sys/kern/kern_pledge.c b/sys/kern/kern_pledge.c
index 9402d1e98eb..990f8f4a338 100644
--- a/sys/kern/kern_pledge.c
+++ b/sys/kern/kern_pledge.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: kern_pledge.c,v 1.7 2015/10/10 14:46:15 deraadt Exp $ */
+/* $OpenBSD: kern_pledge.c,v 1.8 2015/10/10 14:48:03 deraadt Exp $ */
/*
* Copyright (c) 2015 Nicholas Marriott <nicm@openbsd.org>
@@ -881,6 +881,9 @@ pledge_sysctl_check(struct proc *p, int miblen, int *mib, void *new)
if (miblen == 2 && /* uname() */
mib[0] == CTL_KERN && mib[1] == KERN_VERSION)
return (0);
+ if (miblen == 2 && /* kern.clockrate */
+ mib[0] == CTL_KERN && mib[1] == KERN_CLOCKRATE)
+ return (0);
if (miblen == 2 && /* uname() */
mib[0] == CTL_HW && mib[1] == HW_MACHINE)
return (0);