artulab
projects
/
openbsd
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
41daea4
)
Check that unsupported operation returns ENOSYS.
author
mpi
<mpi@openbsd.org>
Sun, 30 Apr 2017 10:11:03 +0000
(10:11 +0000)
committer
mpi
<mpi@openbsd.org>
Sun, 30 Apr 2017 10:11:03 +0000
(10:11 +0000)
regress/sys/kern/futex/futex.c
patch
|
blob
|
history
diff --git
a/regress/sys/kern/futex/futex.c
b/regress/sys/kern/futex/futex.c
index
643aa05
..
f60f936
100644
(file)
--- a/
regress/sys/kern/futex/futex.c
+++ b/
regress/sys/kern/futex/futex.c
@@
-1,4
+1,4
@@
-/* $OpenBSD: futex.c,v 1.
1 2017/04/30 09:03:58
mpi Exp $ */
+/* $OpenBSD: futex.c,v 1.
2 2017/04/30 10:11:03
mpi Exp $ */
/*
* Copyright (c) 2017 Martin Pieuchot
*
@@
-40,6
+40,9
@@
main(int argc, char *argv[])
struct timespec abs = { 0, 5000 };
pthread_t thread;
+ /* Invalid operation */
+ assert(futex(&lock, 0xFFFF, 0, 0, NULL) == ENOSYS);
+
/* Incorrect pointer */
assert(futex_twait((void *)0xdeadbeef, 1, 0, NULL) == EFAULT);