[d3d12] Avoid panic on instance drop (#5134)

This commit is contained in:
Okko Hakola authored and Connor Fitzgerald committed 2024-02-29 15:53:31 -05:00
1 parent b8a8ff6e44
commit 446a3dcdbf
2 files changed
+11 -2

No files matched your search

+8 -1
View File
@@ -61,11 +61,18 @@ Bottom level categories:
- `tan`
- `tanh`
## v0.19.1 (2024-01-21)
## v0.19.2 (2024-02-29)
### Bug Fixes
#### DX12
- Fix `panic!` when dropping `Instance` without `InstanceFlags::VALIDATION`. By @hakolao in [#5134](https://github.com/gfx-rs/wgpu/pull/5134)
## v0.19.1 (2024-01-21)
### Bug Fixes
#### WGL
- Properly register all swapchain buffers to prevent error on surface present. By @dtzxporter in [#5091](https://github.com/gfx-rs/wgpu/pull/5091)
- Check for extra null states when creating resources. By @nical in [#5096](https://github.com/gfx-rs/wgpu/pull/5096)
+3 -1
View File
@@ -7,7 +7,9 @@ use std::{mem, sync::Arc};
impl Drop for super::Instance {
fn drop(&mut self) {
crate::auxil::dxgi::exception::unregister_exception_handler();
if self.flags.contains(wgt::InstanceFlags::VALIDATION) {
crate::auxil::dxgi::exception::unregister_exception_handler();
}
}
}