diff options
author | Shauren <shauren.trinity@gmail.com> | 2011-05-11 21:19:22 +0200 |
---|---|---|
committer | Shauren <shauren.trinity@gmail.com> | 2011-05-11 21:19:22 +0200 |
commit | 53b409e756571581769b50a01b5bb69e161d3dc3 (patch) | |
tree | 9f4f5f95da4185f46355cda3b5d09b3f81c44feb | |
parent | 2c86e193f37ff178877f72387fb77fa209d35e45 (diff) |
Core/SAI: Fixed memory leak
-rw-r--r-- | src/server/game/AI/SmartScripts/SmartScript.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/server/game/AI/SmartScripts/SmartScript.cpp b/src/server/game/AI/SmartScripts/SmartScript.cpp index 13691882459..624e0e40da1 100644 --- a/src/server/game/AI/SmartScripts/SmartScript.cpp +++ b/src/server/game/AI/SmartScripts/SmartScript.cpp @@ -742,7 +742,7 @@ void SmartScript::ProcessAction(SmartScriptHolder& e, Unit* unit, uint32 var0, u CAST_AI(SmartAI, me->AI())->SetFollow((*itr)->ToUnit(), (float)e.action.follow.dist, (float)e.action.follow.angle, e.action.follow.credit, e.action.follow.entry, e.action.follow.creditType); sLog->outDebug(LOG_FILTER_DATABASE_AI, "SmartScript::ProcessAction: SMART_ACTION_FOLLOW: Creature %u following target %u", me->GetGUIDLow(), (*itr)->GetGUIDLow()); - return; + break; } } @@ -1017,10 +1017,10 @@ void SmartScript::ProcessAction(SmartScriptHolder& e, Unit* unit, uint32 var0, u if (IsUnit(*itr)) { me->AI()->AttackStart((*itr)->ToUnit()); - delete targets; - return; + break; } } + delete targets; break; } case SMART_ACTION_SUMMON_CREATURE: |