Explorar el Código

Revert "Fix crash for disconnecting client"

This reverts commit 28ab1e977712a4754cccd51360be973b45190cbe.
nordsoft hace 3 años
padre
commit
0adae7bb0d
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1 1
      lib/mapObjects/CGTownInstance.h

+ 1 - 1
lib/mapObjects/CGTownInstance.h

@@ -349,7 +349,7 @@ public:
 
 	inline bool isBattleOutsideTown(const CGHeroInstance * defendingHero) const
 	{
-		return defendingHero && defendingHero != garrisonHero;
+		return defendingHero && garrisonHero && defendingHero != garrisonHero;
 	}
 protected:
 	void setPropertyDer(ui8 what, ui32 val) override;