fix unitialized struct UB (#4808)

This commit is contained in:
sneed 2024-06-15 22:20:10 +03:00 committed by GitHub
parent 22994c79d4
commit e5e38c13f3
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -450,7 +450,7 @@ static void SetBattlerAiMovesData(struct AiLogicData *aiData, u32 battlerAtk, u3
SetBattlerData(battlerDef);
for (i = 0; i < MAX_MON_MOVES; i++)
{
struct SimulatedDamage dmg;
struct SimulatedDamage dmg = {0};
u8 effectiveness = AI_EFFECTIVENESS_x0;
u32 move = moves[i];