This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] pthread_mutex_unlock: fix wrong assertion with lock elision (bug#19515)


On 2016-01-23 22:38, Andreas Schwab wrote:
> Aurelien Jarno <aurelien@aurel32.net> writes:
> 
> > 	[BZ #19515]
> > 	* nptl/pthread_mutex_unlock.c (__pthread_mutex_unlock_usercnt):
> > 	Use PTHREAD_MUTEX_TYPE to get the mutex type.
> 
> That doesn't fix the bug.  The correct patch is at
> <http://permalink.gmane.org/gmane.comp.lib.glibc.alpha/58565>.

Thanks for the link and sorry for the duplicate bug. While I agree your
patch is correct to fix the issue, I still believe the assert is wrongly
accessing the mutex type directly. It might work, but that is something
fragile that might break if the mutex flags are changed.

-- 
Aurelien Jarno                          GPG: 4096R/1DDD8C9B
aurelien@aurel32.net                 http://www.aurel32.net


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]