aboutsummaryrefslogtreecommitdiffstats
path: root/erts/lib_src/common
diff options
context:
space:
mode:
authorRickard Green <[email protected]>2010-12-06 10:32:01 +0100
committerRickard Green <[email protected]>2010-12-06 10:32:01 +0100
commitf1c8231c16ca4cc8ef39318364ac8a1c8d7d56e1 (patch)
tree386f62452e2aa87593e6d7f2ae7e9b5af87df8f8 /erts/lib_src/common
parent1ad422e1a745f5e20beb4a3612c499ec2472530d (diff)
parent1108ed8660f376b661ea04b86a83c20339106353 (diff)
downloadotp-f1c8231c16ca4cc8ef39318364ac8a1c8d7d56e1.tar.gz
otp-f1c8231c16ca4cc8ef39318364ac8a1c8d7d56e1.tar.bz2
otp-f1c8231c16ca4cc8ef39318364ac8a1c8d7d56e1.zip
Merge branch 'rickard/rwmutex-bug/OTP-8925' into dev
* rickard/rwmutex-bug/OTP-8925: Fix erroneous assertion
Diffstat (limited to 'erts/lib_src/common')
-rw-r--r--erts/lib_src/common/ethr_mutex.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/erts/lib_src/common/ethr_mutex.c b/erts/lib_src/common/ethr_mutex.c
index 95fedc0ba2..a2fbf3a454 100644
--- a/erts/lib_src/common/ethr_mutex.c
+++ b/erts/lib_src/common/ethr_mutex.c
@@ -2101,7 +2101,10 @@ rwmutex_unlock_wake(ethr_rwmutex *rwmtx, int have_w, long initial,
if (!have_w) {
act = ethr_atomic_read_bor(&rwmtx->mtxb.flgs,
ETHR_RWMTX_W_FLG__);
- ETHR_ASSERT((act & ~ETHR_RWMTX_WAIT_FLGS__) == 0);
+ ETHR_ASSERT((act & ~(ETHR_RWMTX_WAIT_FLGS__
+ | (rwmtx->type == ETHR_RWMUTEX_TYPE_NORMAL
+ ? 0
+ : ETHR_RWMTX_R_PEND_UNLCK_MASK__))) == 0);
ETHR_ASSERT(act & ETHR_RWMTX_W_WAIT_FLG__);
act |= ETHR_RWMTX_W_FLG__;
}