Call tdetach in nptl_detach if needed
authorDavid Bartley <dtbartle@glibc.(none)>
Fri, 13 Feb 2009 02:39:28 +0000 (02:39 +0000)
committerDavid Bartley <dtbartle@glibc.(none)>
Fri, 13 Feb 2009 02:39:28 +0000 (02:39 +0000)
nptl/pthread_detach.c

index bcb14e2..68d9a8b 100644 (file)
@@ -56,6 +56,13 @@ pthread_detach (th)
       /* Note that the code in __free_tcb makes sure each thread
         control block is freed only once.  */
       __free_tcb (pd);
+#ifdef NEED_TDETACH
+    else
+      {
+        INTERNAL_SYSCALL_DECL (err);
+        result = INTERNAL_SYSCALL (tdetach, err, 1, th);
+      }
+#endif
 
   return result;
 }