From: Ulrich Drepper Date: Wed, 12 Mar 2003 08:41:10 +0000 (+0000) Subject: Return result of lock re-get if it fails. X-Git-Tag: cvs/glibc-2_3_3~1273 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a3cd7da30f9ac88b43c913ef0c5b5a014e0dd2e7;p=thirdparty%2Fglibc.git Return result of lock re-get if it fails. --- diff --git a/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S b/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S index f11a44ec431..811741b06d7 100644 --- a/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S +++ b/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S @@ -206,14 +206,15 @@ __pthread_cond_timedwait: call __pthread_mutex_lock_internal addl $36, %esp - movl %esi, %eax + /* We return the result of the mutex_lock operation if it failed. */ + testl %eax, %eax + cmovel %esi, %eax 18: popl %ebx popl %esi popl %edi popl %ebp - /* We return the result of the mutex_lock operation. */ ret /* Initial locking failed. */