From e25846a08ee15a9bc4c1e55d58c3c64f240ea21c Mon Sep 17 00:00:00 2001 From: Shauren Date: Thu, 2 Sep 2010 22:04:08 +0200 Subject: [PATCH] Core/Spells: Fixed crash in EffectFeedPet Closes issue #3728. Closes issue #3752. --HG-- branch : trunk --- src/server/game/Spells/SpellEffects.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/server/game/Spells/SpellEffects.cpp b/src/server/game/Spells/SpellEffects.cpp index 3b177cfc57..fc847e7787 100644 --- a/src/server/game/Spells/SpellEffects.cpp +++ b/src/server/game/Spells/SpellEffects.cpp @@ -5794,12 +5794,12 @@ void Spell::EffectFeedPet(SpellEffIndex effIndex) if (benefit <= 0) return; - uint32 count = 1; - _player->DestroyItemCount(foodItem,count,true); - // TODO: fix crash when a spell has two effects, both pointed at the same item target - ExecuteLogEffectDestroyItem(effIndex, foodItem->GetEntry()); + uint32 count = 1; + _player->DestroyItemCount(foodItem, count, true); + // TODO: fix crash when a spell has two effects, both pointed at the same item target + m_caster->CastCustomSpell(pet, m_spellInfo->EffectTriggerSpell[effIndex], &benefit, NULL, NULL, true); }