about summary refs log tree commit diff
path: root/nptl/allocatestack.c
diff options
context:
space:
mode:
authorJakub Jelinek <jakub@redhat.com>2006-02-13 07:30:06 +0000
committerJakub Jelinek <jakub@redhat.com>2006-02-13 07:30:06 +0000
commitbb786851edfb584a36b3f2674eb024af6f33f319 (patch)
tree4243fee7b513ae79b63f94593d5e9e0b2bbe86c5 /nptl/allocatestack.c
parenta7343889536746d3c1902f85c2075ee19ee58c7a (diff)
downloadglibc-bb786851edfb584a36b3f2674eb024af6f33f319.tar.gz
glibc-bb786851edfb584a36b3f2674eb024af6f33f319.tar.xz
glibc-bb786851edfb584a36b3f2674eb024af6f33f319.zip
Updated to fedora-glibc-20060213T0650
Diffstat (limited to 'nptl/allocatestack.c')
-rw-r--r--nptl/allocatestack.c15
1 files changed, 13 insertions, 2 deletions
diff --git a/nptl/allocatestack.c b/nptl/allocatestack.c
index e6bcc2170f..046a2470fc 100644
--- a/nptl/allocatestack.c
+++ b/nptl/allocatestack.c
@@ -1,5 +1,4 @@
-/* Copyright (C) 2002, 2003, 2004, 2005
-   Free Software Foundation, Inc.
+/* Copyright (C) 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@redhat.com>, 2002.
 
@@ -366,6 +365,12 @@ allocate_stack (const struct pthread_attr *attr, struct pthread **pdp,
       /* The process ID is also the same as that of the caller.  */
       pd->pid = THREAD_GETMEM (THREAD_SELF, pid);
 
+      /* List of robust mutexes.  */
+#ifdef __PTHREAD_MUTEX_HAVE_PREV
+      pd->robust_list.__prev = &pd->robust_list;
+#endif
+      pd->robust_list.__next = &pd->robust_list;
+
       /* Allocate the DTV for this thread.  */
       if (_dl_allocate_tls (TLS_TPADJ (pd)) == NULL)
 	{
@@ -500,6 +505,12 @@ allocate_stack (const struct pthread_attr *attr, struct pthread **pdp,
 	  /* The process ID is also the same as that of the caller.  */
 	  pd->pid = THREAD_GETMEM (THREAD_SELF, pid);
 
+	  /* List of robust mutexes.  */
+#ifdef __PTHREAD_MUTEX_HAVE_PREV
+	  pd->robust_list.__prev = &pd->robust_list;
+#endif
+	  pd->robust_list.__next = &pd->robust_list;
+
 	  /* Allocate the DTV for this thread.  */
 	  if (_dl_allocate_tls (TLS_TPADJ (pd)) == NULL)
 	    {