pthread_key_delete wants the key itself, not a pointer to it
authorIan Lynagh <igloo@earth.li>
Fri, 23 Feb 2007 12:23:12 +0000 (12:23 +0000)
committerIan Lynagh <igloo@earth.li>
Fri, 23 Feb 2007 12:23:12 +0000 (12:23 +0000)
rts/posix/OSThreads.c

index 6b6fa5c..510a51d 100644 (file)
@@ -152,7 +152,7 @@ void
 freeThreadLocalKey (ThreadLocalKey *key)
 {
     int r;
-    if ((r = pthread_key_delete(key)) != 0) {
+    if ((r = pthread_key_delete(*key)) != 0) {
        barf("freeThreadLocalKey: %s", strerror(r));
     }
 }