Core/Misc: Fix issues reported by static analysis

Coverity defect IDs: 1292760, 1292761, 1292762, 1292771, 1292770
This commit is contained in:
jackpoz committed 2015-04-04 12:44:56 +02:00
1 parent 1a2c20f95d
commit 25e86f75f8
4 files changed
+5 -12

No files matched your search

+1 -6
View File
@@ -21532,12 +21532,7 @@ void Player::ProhibitSpellSchool(SpellSchoolMask idSchoolMask, uint32 unTimeMs)
if (itr->second->state == PLAYERSPELL_REMOVED)
continue;
uint32 unSpellId = itr->first;
SpellInfo const* spellInfo = sSpellMgr->GetSpellInfo(unSpellId);
if (!spellInfo)
{
ASSERT(spellInfo);
continue;
}
SpellInfo const* spellInfo = sSpellMgr->EnsureSpellInfo(unSpellId);
// Not send cooldown for this spells
if (spellInfo->IsCooldownStartedOnEvent())