Ver Fonte

Fixed infinite loop

Ivan Savenko há 2 anos atrás
pai
commit
55d0f0ad9f
1 ficheiros alterados com 1 adições e 2 exclusões
  1. 1 2
      client/battle/BattleProjectileController.cpp

+ 1 - 2
client/battle/BattleProjectileController.cpp

@@ -225,9 +225,8 @@ void BattleProjectileController::emitStackProjectile(const CStack * stack)
 
 void BattleProjectileController::showProjectiles(Canvas & canvas)
 {
-	for ( auto it = projectiles.begin(); it != projectiles.end();)
+	for ( auto projectile: projectiles)
 	{
-		auto projectile = *it;
 		if ( projectile->playing )
 			projectile->show(canvas);
 	}