mirror of
https://sourceware.org/git/glibc.git
synced 2025-07-29 11:41:21 +03:00
.
This commit is contained in:
@ -1,4 +1,4 @@
|
||||
/* Copyright (C) 2002, 2003, 2005, 2006 Free Software Foundation, Inc.
|
||||
/* Copyright (C) 2002, 2003, 2005, 2006, 2007 Free Software Foundation, Inc.
|
||||
This file is part of the GNU C Library.
|
||||
Contributed by Ulrich Drepper <drepper@redhat.com>, 2002.
|
||||
|
||||
@ -91,9 +91,11 @@ __pthread_mutex_trylock (mutex)
|
||||
if ((oldval & FUTEX_OWNER_DIED) != 0)
|
||||
{
|
||||
/* The previous owner died. Try locking the mutex. */
|
||||
int newval
|
||||
int newval = id | (oldval & FUTEX_WAITERS);
|
||||
|
||||
newval
|
||||
= atomic_compare_and_exchange_val_acq (&mutex->__data.__lock,
|
||||
id, oldval);
|
||||
newval, oldval);
|
||||
|
||||
if (newval != oldval)
|
||||
{
|
||||
|
Reference in New Issue
Block a user