SeqWait: don't do wakeups under the lock

Clippy pointed out that `drop(waiters)` didn't do anything, because
there was a misplaced ";" causing `waiters` to be a unit type `()`.

This change makes it do what was intended: the lock should be dropped
first, then the wakeups should be processed.
This commit is contained in:
Eric Seppanen
2021-04-23 14:10:43 -07:00
parent 499b4f7eba
commit 8beaf76c85

View File

@@ -63,7 +63,7 @@ impl SeqWait {
// This will steal the entire waiters map.
// When we drop it all waiters will be woken.
mem::take(&mut internal.waiters);
mem::take(&mut internal.waiters)
// Drop the lock as we exit this scope.
};