diff options
| author | megamage <none@none> | 2009-03-07 00:52:30 -0600 | 
|---|---|---|
| committer | megamage <none@none> | 2009-03-07 00:52:30 -0600 | 
| commit | 6ae4f909d0640c6ad3880459a340ee747c75693b (patch) | |
| tree | 7a5cb0ee677e6e9897a73eab6befd3c308929bd9 /src | |
| parent | b49732c04db0d5bf67bf78e73e9c22f2078fd47c (diff) | |
*Fix a crash caused by possesspet spells.
--HG--
branch : trunk
Diffstat (limited to 'src')
| -rw-r--r-- | src/game/SpellAuras.cpp | 7 | 
1 files changed, 5 insertions, 2 deletions
diff --git a/src/game/SpellAuras.cpp b/src/game/SpellAuras.cpp index 40edea80ce9..034370f9564 100644 --- a/src/game/SpellAuras.cpp +++ b/src/game/SpellAuras.cpp @@ -2873,11 +2873,14 @@ void Aura::HandleModPossessPet(bool apply, bool Real)      Unit* caster = GetCaster();      if(!caster || caster->GetTypeId() != TYPEID_PLAYER)          return; -    if(caster->GetPet() != m_target) -        return;      if(apply) +    { +        if(caster->GetPet() != m_target) +            return; +          m_target->SetCharmedOrPossessedBy(caster, true); +    }      else      {          m_target->RemoveCharmedOrPossessedBy(caster);  | 
