Skip to content
Snippets Groups Projects
Commit 9a39f854 authored by Guido Trotter's avatar Guido Trotter
Browse files

SharedLock: remove wrong assertion in code

r644 contained some cleanup code for LockSet. Among other things it removed a
syntax error that allowed an assertion that previously wan't really checked to
trigger. It turns out that even though the spirit of that assertion was correct
its actual implementation was wrong.

While it's true that no sharers must be waiting if an exclusive holder is not
present it might happen that when all the sharers wake up one of them releases
the lock before some other even has had a chance to run. In this case
__shr_wait would still be greater than 0, even if the sharer is not actually
waiting, just pending a wakeup to proceed.

Thus, removing the assertion in question.

Reviewed-by: imsnah
parent cdb08f44
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment