summaryrefslogtreecommitdiff
path: root/sys/kern/kern_sysctl.c
diff options
context:
space:
mode:
authorMark Kettenis <kettenis@cvs.openbsd.org>2010-05-02 11:15:30 +0000
committerMark Kettenis <kettenis@cvs.openbsd.org>2010-05-02 11:15:30 +0000
commit2cbb14893098445118dbd76eb3a6da56a4848f23 (patch)
tree7f96c922b39f82787b8db274ed1b1d7e5243b4ca /sys/kern/kern_sysctl.c
parentaa21ef7541a3118da61e9f0b759077a58b9d0f00 (diff)
Use intermediate vaddr_t cast when casting a pointer to off_t. Prevents
gcc4 from complaining about casting a pointer to an integer type of different size. ok guenther@, jsg@
Diffstat (limited to 'sys/kern/kern_sysctl.c')
-rw-r--r--sys/kern/kern_sysctl.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/kern/kern_sysctl.c b/sys/kern/kern_sysctl.c
index 35fe3238fad..ee566720b8b 100644
--- a/sys/kern/kern_sysctl.c
+++ b/sys/kern/kern_sysctl.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: kern_sysctl.c,v 1.182 2010/04/20 20:49:33 deraadt Exp $ */
+/* $OpenBSD: kern_sysctl.c,v 1.183 2010/05/02 11:15:29 kettenis Exp $ */
/* $NetBSD: kern_sysctl.c,v 1.17 1996/05/20 17:49:05 mrg Exp $ */
/*-
@@ -1646,7 +1646,7 @@ sysctl_proc_args(int *name, u_int namelen, void *oldp, size_t *oldlenp,
iov.iov_len = sizeof(pss);
uio.uio_iov = &iov;
uio.uio_iovcnt = 1;
- uio.uio_offset = (off_t)PS_STRINGS;
+ uio.uio_offset = (off_t)(vaddr_t)PS_STRINGS;
uio.uio_resid = sizeof(pss);
uio.uio_segflg = UIO_SYSSPACE;
uio.uio_rw = UIO_READ;