diff options
Diffstat (limited to 'test/sanitizer_common/TestCases/Linux/sched_getparam.cc')
-rw-r--r-- | test/sanitizer_common/TestCases/Linux/sched_getparam.cc | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/test/sanitizer_common/TestCases/Linux/sched_getparam.cc b/test/sanitizer_common/TestCases/Linux/sched_getparam.cc new file mode 100644 index 000000000000..390c656fe209 --- /dev/null +++ b/test/sanitizer_common/TestCases/Linux/sched_getparam.cc @@ -0,0 +1,13 @@ +// RUN: %clangxx -O0 %s -o %t && %run %t + +#include <assert.h> +#include <sched.h> +#include <stdio.h> + +int main(void) { + struct sched_param param; + int res = sched_getparam(0, ¶m); + assert(res == 0); + if (param.sched_priority == 42) printf(".\n"); + return 0; +} |