Skip to content

Commit

Permalink
fix assert/crash
Browse files Browse the repository at this point in the history
  • Loading branch information
petiaccja committed Feb 20, 2024
1 parent 9b2e052 commit 0e5353b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/shared_mutex.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,8 @@ void shared_mutex::continue_waiting(std::unique_lock<spinlock>& lk) {

void shared_mutex::unlock() {
std::unique_lock lk(m_spinlock);
assert(m_queue.pop_front() == &m_exclusive_sentinel);
assert(m_queue.front() == &m_exclusive_sentinel);
m_queue.pop_front();
continue_waiting(lk);
}

Expand Down

0 comments on commit 0e5353b

Please sign in to comment.