From 5f66b766e7b1929b07ab3e0374a9a627a45c9be6 Mon Sep 17 00:00:00 2001 From: Ulrich Drepper Date: Sat, 25 Sep 2004 07:44:41 +0000 Subject: Update. 2004-09-25 Jakub Jelinek * sysdeps/unix/sysv/linux/i386/setuid.c (__setuid): Remove second result declaration. 2004-09-22 Andreas Schwab * sysdeps/unix/sysv/linux/ia64/sysdep.h: Adjust whitespace. --- nptl/pthread_create.c | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) (limited to 'nptl/pthread_create.c') diff --git a/nptl/pthread_create.c b/nptl/pthread_create.c index 34cc37d527..1bab72d1e9 100644 --- a/nptl/pthread_create.c +++ b/nptl/pthread_create.c @@ -252,14 +252,17 @@ start_thread (void *arg) /* Store the new cleanup handler info. */ THREAD_SETMEM (pd, cleanup_jmp_buf, &unwind_buf); - int oldtype = CANCEL_ASYNC (); + if (__builtin_expect (pd->stopped_start, 0)) + { + int oldtype = CANCEL_ASYNC (); - /* Get the lock the parent locked to force synchronization. */ - lll_lock (pd->lock); - /* And give it up right away. */ - lll_unlock (pd->lock); + /* Get the lock the parent locked to force synchronization. */ + lll_lock (pd->lock); + /* And give it up right away. */ + lll_unlock (pd->lock); - CANCEL_RESET (oldtype); + CANCEL_RESET (oldtype); + } /* Run the code the user provided. */ #ifdef CALL_THREAD_FCT -- cgit 1.4.1