Browse Source

core: Don't shutdown a null GPU

When CreateGPU fails, yuzu would try and shutdown the GPU instance
regardless of whether any instance was actually created.

Check for nullptr before calling its methods to prevent a crash.
nce_cpp
lat9nq 4 years ago
parent
commit
7df809b8b1
  1. 2
      src/core/core.cpp

2
src/core/core.cpp

@ -326,7 +326,9 @@ struct System::Impl {
is_powered_on = false;
exit_lock = false;
if (gpu_core != nullptr) {
gpu_core->NotifyShutdown();
}
services.reset();
service_manager.reset();

Loading…
Cancel
Save