summaryrefslogtreecommitdiff
path: root/src/mutex/guard.rs
diff options
context:
space:
mode:
authorBotahamec <botahamec@outlook.com>2024-12-21 11:27:09 -0500
committerBotahamec <botahamec@outlook.com>2024-12-21 11:27:09 -0500
commitb2281e6aec631dc7c6d69edef9268ce7e00ed1dc (patch)
tree4a3d9059e291016dcfaec8b08ac4aee48a7b815a /src/mutex/guard.rs
parent0ddbb5efa57fb36b2c83a5cd1dc43a5cf426e3ee (diff)
Implement lock death, but without any usages
Diffstat (limited to 'src/mutex/guard.rs')
-rw-r--r--src/mutex/guard.rs3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/mutex/guard.rs b/src/mutex/guard.rs
index 8b2b1aa..c255996 100644
--- a/src/mutex/guard.rs
+++ b/src/mutex/guard.rs
@@ -5,6 +5,7 @@ use std::ops::{Deref, DerefMut};
use lock_api::RawMutex;
use crate::key::Keyable;
+use crate::lockable::RawLock;
use super::{Mutex, MutexGuard, MutexRef};
@@ -27,7 +28,7 @@ impl<'a, T: ?Sized + 'a, R: RawMutex> Drop for MutexRef<'a, T, R> {
fn drop(&mut self) {
// safety: this guard is being destroyed, so the data cannot be
// accessed without locking again
- unsafe { self.0.force_unlock() }
+ unsafe { self.0.raw_unlock() }
}
}