mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-07-11 01:25:07 +02:00
Fix exit crash on Windows ARM64 with D3D11 (and probably also x64 Windows, but couldn't repro that)
This commit is contained in:
@@ -335,6 +335,7 @@ void MainThreadFunc() {
|
||||
g_graphicsContext->Shutdown();
|
||||
|
||||
delete g_graphicsContext;
|
||||
g_graphicsContext = nullptr;
|
||||
|
||||
RECT rc;
|
||||
if (console && GetWindowRect(console, &rc) && !IsIconic(console)) {
|
||||
|
||||
@@ -256,6 +256,19 @@ void D3D11Context::Shutdown() {
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifdef _DEBUG
|
||||
d3dDebug_ = nullptr;
|
||||
d3dInfoQueue_ = nullptr;
|
||||
#endif
|
||||
|
||||
// Important that we release before we unload the DLL, otherwise we may crash on shutdown.
|
||||
bbRenderTargetTex_ = nullptr;
|
||||
bbRenderTargetView_ = nullptr;
|
||||
context1_ = nullptr;
|
||||
context_ = nullptr;
|
||||
device1_ = nullptr;
|
||||
device_ = nullptr;
|
||||
hWnd_ = nullptr;
|
||||
|
||||
UnloadD3D11();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user