mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-23 10:26:28 +01:00
Core/Misc: Fix issues reported by static analysis
Fix issues reported by Coverity Scan
(cherry picked from commit 2fda1572d2)
This commit is contained in:
@@ -113,7 +113,7 @@ struct PositionFullTerrainStatus
|
||||
uint32 const mogpFlags;
|
||||
};
|
||||
|
||||
PositionFullTerrainStatus() : areaId(0), floorZ(0.0f), outdoors(true) { }
|
||||
PositionFullTerrainStatus() : areaId(0), floorZ(0.0f), outdoors(true), liquidStatus(LIQUID_MAP_NO_WATER) { }
|
||||
uint32 areaId;
|
||||
float floorZ;
|
||||
bool outdoors;
|
||||
|
||||
@@ -90,7 +90,7 @@ protected:
|
||||
|
||||
public:
|
||||
|
||||
explicit SplineBase() : index_lo(0), index_hi(0), m_mode(UninitializedMode), cyclic(false) { }
|
||||
explicit SplineBase() : index_lo(0), index_hi(0), m_mode(UninitializedMode), cyclic(false), initialOrientation(0.f) { }
|
||||
|
||||
/** Caclulates the position for given segment Idx, and percent of segment length t
|
||||
@param t - percent of segment length, assumes that t in range [0, 1]
|
||||
|
||||
@@ -533,7 +533,7 @@ public:
|
||||
return true;
|
||||
}
|
||||
|
||||
handler->PSendSysMessage(LANG_COMMAND_GO_INSTANCE_FAILED, mapid, scriptname.c_str(), exit->target_mapId);
|
||||
handler->PSendSysMessage(LANG_COMMAND_GO_INSTANCE_FAILED, mapid, scriptname.c_str(), exit ? exit->target_mapId : uint32(-1));
|
||||
handler->SetSentErrorMessage(true);
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -1159,7 +1159,7 @@ class spell_algalon_big_bang : public SpellScript
|
||||
AfterCast += SpellCastFn(spell_algalon_big_bang::CheckTargets);
|
||||
}
|
||||
private:
|
||||
uint32 _targetCount;
|
||||
uint32 _targetCount = 0;
|
||||
};
|
||||
|
||||
// 64445 - Remove Player from Phase
|
||||
|
||||
@@ -955,7 +955,7 @@ class spell_xt002_exposed_heart : public AuraScript
|
||||
}
|
||||
|
||||
private:
|
||||
uint32 _damageAmount;
|
||||
uint32 _damageAmount = 0;
|
||||
};
|
||||
|
||||
class achievement_nerf_engineering : public AchievementCriteriaScript
|
||||
|
||||
Reference in New Issue
Block a user