summaryrefslogtreecommitdiff
path: root/lib/libc/sys/mquery.c
diff options
context:
space:
mode:
authorPhilip Guenthe <guenther@cvs.openbsd.org>2011-10-16 06:29:57 +0000
committerPhilip Guenthe <guenther@cvs.openbsd.org>2011-10-16 06:29:57 +0000
commitc88c9da9de80c953720b63f23dfe9904e3792861 (patch)
treeb6831173c0658dcb35f5c809fa0b00542d700a79 /lib/libc/sys/mquery.c
parent2a45f95d13665d24e0b297ff465f09d691dfb1bf (diff)
Make consistent the syscall stubs for the syscalls that got special
handling to fix up the alignment of 64bit arguments so that they do the same dance where _thread_sys_FOO is the real stub and FOO is a weak alias. For some of them, this is needed for cancellation handling. From discussions with fgsch@, ok millert@
Diffstat (limited to 'lib/libc/sys/mquery.c')
-rw-r--r--lib/libc/sys/mquery.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/lib/libc/sys/mquery.c b/lib/libc/sys/mquery.c
index d22ce89ad26..53b27f971de 100644
--- a/lib/libc/sys/mquery.c
+++ b/lib/libc/sys/mquery.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: mquery.c,v 1.6 2005/04/06 16:56:45 millert Exp $ */
+/* $OpenBSD: mquery.c,v 1.7 2011/10/16 06:29:56 guenther Exp $ */
/*
* Written by Artur Grabowski <art@openbsd.org> Public Domain
*/
@@ -6,14 +6,20 @@
#include <sys/types.h>
#include <sys/mman.h>
#include <sys/syscall.h>
+#include "thread_private.h"
register_t __syscall(quad_t, ...);
+STUB_PROTOTYPE(mquery);
+
+STUB_ALIAS(mquery);
+
/*
* This function provides 64-bit offset padding.
*/
void *
-mquery(void *addr, size_t len, int prot, int flags, int fd, off_t offset)
+STUB_NAME(mquery)(void *addr, size_t len, int prot, int flags, int fd,
+ off_t offset)
{
return((void *)__syscall((quad_t)SYS_mquery, addr, len, prot,
flags, fd, 0, offset));