aboutsummaryrefslogtreecommitdiff
path: root/src/game/SpellEffects.cpp
diff options
context:
space:
mode:
authormegamage <none@none>2009-03-20 14:23:25 -0600
committermegamage <none@none>2009-03-20 14:23:25 -0600
commitd7e05e8003a095db6e10c470d96a80f431046099 (patch)
treec4df7751b99bdc58350cda37b08579dbf2b23b32 /src/game/SpellEffects.cpp
parent7f130ba9717902a56439d660d17f31b00dded470 (diff)
*Fix some out-of-range array indices of totem slot and charm spell slot.
--HG-- branch : trunk
Diffstat (limited to 'src/game/SpellEffects.cpp')
-rw-r--r--src/game/SpellEffects.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/game/SpellEffects.cpp b/src/game/SpellEffects.cpp
index 583087a5106..775ac762cd2 100644
--- a/src/game/SpellEffects.cpp
+++ b/src/game/SpellEffects.cpp
@@ -6539,7 +6539,7 @@ void Spell::SummonTotem(uint32 entry, SummonPropertiesEntry const *properties)
pTotem->Relocate(x, y, z, m_caster->GetOrientation());
- if(slot < MAX_TOTEM)
+ if(slot >= 0 && slot < MAX_TOTEM)
m_caster->m_TotemSlot[slot] = pTotem->GetGUID();
pTotem->SetOwner(m_caster->GetGUID());