diff options
Diffstat (limited to 'compiler/rustc_errors/src')
| -rw-r--r-- | compiler/rustc_errors/src/lock.rs | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/compiler/rustc_errors/src/lock.rs b/compiler/rustc_errors/src/lock.rs index bd5cf49b56b..0aeb511214b 100644 --- a/compiler/rustc_errors/src/lock.rs +++ b/compiler/rustc_errors/src/lock.rs @@ -27,7 +27,8 @@ pub fn acquire_global_lock(name: &str) -> Box<dyn Any> { impl Drop for Handle { fn drop(&mut self) { unsafe { - CloseHandle(self.0); + // FIXME can panic here + CloseHandle(self.0).unwrap(); } } } @@ -37,7 +38,8 @@ pub fn acquire_global_lock(name: &str) -> Box<dyn Any> { impl Drop for Guard { fn drop(&mut self) { unsafe { - ReleaseMutex((self.0).0); + // FIXME can panic here + ReleaseMutex((self.0).0).unwrap(); } } } |
