about summary refs log tree commit diff
path: root/elf
diff options
context:
space:
mode:
Diffstat (limited to 'elf')
-rw-r--r--elf/tst-execstack.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/elf/tst-execstack.c b/elf/tst-execstack.c
index 7e898b4f58..560b353918 100644
--- a/elf/tst-execstack.c
+++ b/elf/tst-execstack.c
@@ -137,7 +137,12 @@ do_test (void)
 #endif
 
   /* Loading this module should force stacks to become executable.  */
-  void *h = dlopen ("tst-execstack-mod.so", RTLD_LAZY);
+#if USE_PTHREADS
+  const char *soname = "tst-execstack-threads-mod.so";
+#else
+  const char *soname = "tst-execstack-mod.so";
+#endif
+  void *h = dlopen (soname, RTLD_LAZY);
   if (h == NULL)
     {
       printf ("cannot load: %s\n", dlerror ());