]>
Commit | Line | Data |
---|---|---|
df47504c UD |
1 | #include <pthread.h> |
2 | #include <stdio.h> | |
3 | #include <stdlib.h> | |
4 | ||
5 | ||
6 | static pthread_mutexattr_t a; | |
7 | ||
8 | static void | |
9 | prepare (void) | |
10 | { | |
11 | if (pthread_mutexattr_init (&a) != 0) | |
12 | { | |
13 | puts ("mutexattr_init failed"); | |
14 | exit (1); | |
15 | } | |
16 | ||
17 | if (pthread_mutexattr_setprotocol (&a, PTHREAD_PRIO_INHERIT) != 0) | |
18 | { | |
19 | puts ("mutexattr_setprotocol failed"); | |
20 | exit (1); | |
21 | } | |
22 | } | |
23 | #define PREPARE(argc, argv) prepare () | |
24 | ||
25 | ||
26 | #define ATTR &a | |
4e0b9016 | 27 | #define ATTR_NULL false |
df47504c | 28 | #include "tst-mutex1.c" |