Explorar o código

Failure when exiting when "system required" thread was not allocated, caused by 4b389600

Source commit: 4e32679b8f1f6f8d082b87d7a169e90c1b4ffd29
Martin Prikryl %!s(int64=3) %!d(string=hai) anos
pai
achega
6c9661a20e
Modificáronse 1 ficheiros con 7 adicións e 3 borrados
  1. 7 3
      source/windows/GUITools.cpp

+ 7 - 3
source/windows/GUITools.cpp

@@ -2382,7 +2382,11 @@ void GUIFinalize()
     Thread = SystemRequiredThread;
     SystemRequiredThread = NULL;
   }
-  Thread->Terminate();
-  Thread->WaitFor();
-  delete Thread;
+
+  if (Thread != NULL)
+  {
+    Thread->Terminate();
+    Thread->WaitFor();
+    delete Thread;
+  }
 }