summaryrefslogtreecommitdiff
path: root/libc/nptl/tst-mutex5.c
diff options
context:
space:
mode:
Diffstat (limited to 'libc/nptl/tst-mutex5.c')
-rw-r--r--libc/nptl/tst-mutex5.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/libc/nptl/tst-mutex5.c b/libc/nptl/tst-mutex5.c
index f19cd8c31..c223f6782 100644
--- a/libc/nptl/tst-mutex5.c
+++ b/libc/nptl/tst-mutex5.c
@@ -22,6 +22,7 @@
#include <time.h>
#include <unistd.h>
#include <sys/time.h>
+#include <config.h>
#ifndef TYPE
@@ -85,6 +86,8 @@ do_test (void)
return 1;
}
+ /* Elided locks do not time out. */
+#ifdef ENABLE_LOCK_ELISION
if (pthread_mutex_trylock (&m) == 0)
{
puts ("mutex_trylock succeeded");
@@ -180,6 +183,7 @@ do_test (void)
puts ("3rd timedlock didn't return right away");
return 1;
}
+#endif
if (pthread_mutex_unlock (&m) != 0)
{