Explorar o código

core: Only wait for idle on gpu_core when it was initialized

This fixes crashes when a Vulkan device fails to initialize.
ReinUsesLisp %!s(int64=6) %!d(string=hai) anos
pai
achega
e651e54b85
Modificáronse 1 ficheiros con 3 adicións e 1 borrados
  1. 3 1
      src/core/core.cpp

+ 3 - 1
src/core/core.cpp

@@ -259,7 +259,9 @@ struct System::Impl {
         is_powered_on = false;
         exit_lock = false;
 
-        gpu_core->WaitIdle();
+        if (gpu_core) {
+            gpu_core->WaitIdle();
+        }
 
         // Shutdown emulation session
         renderer.reset();