Skip to content

Commit

Permalink
Another null check in NativeShutdown
Browse files Browse the repository at this point in the history
  • Loading branch information
hrydgard committed Jan 3, 2023
1 parent f00367d commit 7fbb0c4
Showing 1 changed file with 9 additions and 6 deletions.
15 changes: 9 additions & 6 deletions UI/NativeApp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1498,16 +1498,19 @@ bool NativeIsRestarting() {
}

void NativeShutdown() {
if (screenManager)
if (screenManager) {
screenManager->shutdown();
delete screenManager;
screenManager = nullptr;
delete screenManager;
screenManager = nullptr;
}

host->ShutdownGraphics();
if (host) {
host->ShutdownGraphics();
delete host;
host = nullptr;
}

#if !PPSSPP_PLATFORM(UWP)
delete host;
host = nullptr;
#endif
g_Config.Save("NativeShutdown");

Expand Down

0 comments on commit 7fbb0c4

Please sign in to comment.