svn commit: r352893 - stable/11/lib/libthr/thread
Konstantin Belousov
kib at FreeBSD.org
Mon Sep 30 07:43:00 UTC 2019
Author: kib
Date: Mon Sep 30 07:42:59 2019
New Revision: 352893
URL: https://svnweb.freebsd.org/changeset/base/352893
Log:
MFC r352620:
Fix destruction of the robust mutexes.
Modified:
stable/11/lib/libthr/thread/thr_mutex.c
Directory Properties:
stable/11/ (props changed)
Modified: stable/11/lib/libthr/thread/thr_mutex.c
==============================================================================
--- stable/11/lib/libthr/thread/thr_mutex.c Mon Sep 30 07:42:07 2019 (r352892)
+++ stable/11/lib/libthr/thread/thr_mutex.c Mon Sep 30 07:42:59 2019 (r352893)
@@ -469,7 +469,11 @@ _pthread_mutex_destroy(pthread_mutex_t *mutex)
if (m == THR_PSHARED_PTR) {
m1 = __thr_pshared_offpage(mutex, 0);
if (m1 != NULL) {
- mutex_assert_not_owned(_get_curthread(), m1);
+ if ((uint32_t)m1->m_lock.m_owner !=
+ UMUTEX_RB_OWNERDEAD) {
+ mutex_assert_not_owned(
+ _get_curthread(), m1);
+ }
__thr_pshared_destroy(mutex);
}
*mutex = THR_MUTEX_DESTROYED;
More information about the svn-src-stable-11
mailing list