summary refs log tree commit diff
path: root/sysdeps/pthread/tst-tsd6.c
diff options
context:
space:
mode:
Diffstat (limited to 'sysdeps/pthread/tst-tsd6.c')
-rw-r--r--sysdeps/pthread/tst-tsd6.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/sysdeps/pthread/tst-tsd6.c b/sysdeps/pthread/tst-tsd6.c
index debb1dd367..5f2aa42e98 100644
--- a/sysdeps/pthread/tst-tsd6.c
+++ b/sysdeps/pthread/tst-tsd6.c
@@ -17,7 +17,8 @@ tf (void *arg)
   for (int i = 0; i < NKEYS; ++i)
     {
       void *p = pthread_getspecific (keys[i]);
-      pthread_setspecific (keys[i], (void *) 7);
+      /* Use an arbitrary but valid pointer as the value.  */
+      pthread_setspecific (keys[i], (void *) keys);
       if (p != NULL)
 	res = p;
     }