Explorar el Código

Possible deadlock fixed.

Michał W. Urbańczyk hace 15 años
padre
commit
124f0dd401
Se han modificado 1 ficheros con 5 adiciones y 5 borrados
  1. 5 5
      client/CPlayerInterface.cpp

+ 5 - 5
client/CPlayerInterface.cpp

@@ -1267,11 +1267,7 @@ void CPlayerInterface::update()
 
 	if(terminate_cond.get())
 		return;
-
-	//in some conditions we may receive calls before selection is initialized - we must ignore them
-	if(!adventureInt->selection)
-		return;
-
+	
 	//if there are any waiting dialogs, show them
 	if(dialogs.size() && !showingDialog->get())
 	{
@@ -1280,6 +1276,10 @@ void CPlayerInterface::update()
 		dialogs.pop_front();
 	}
 
+	//in some conditions we may receive calls before selection is initialized - we must ignore them
+	if(!adventureInt->selection && GH.topInt() == adventureInt)
+		return;
+
 	GH.updateTime();
 	GH.handleEvents();