mirror of
https://github.com/launchbadge/sqlx
synced 2024-11-10 14:34:19 +00:00
(sqlite) do not drop notify mutex until after condvar is triggered (#2573)
Signed-off-by: Andrew Whitehead <cywolf@gmail.com>
This commit is contained in:
parent
1b7631eddc
commit
3fbc3a3ff2
1 changed files with 2 additions and 1 deletions
|
@ -57,7 +57,8 @@ impl Notify {
|
|||
}
|
||||
|
||||
fn fire(&self) {
|
||||
*self.mutex.lock().unwrap() = true;
|
||||
let mut lock = self.mutex.lock().unwrap();
|
||||
*lock = true;
|
||||
self.condvar.notify_one();
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue