issues #14050 ActionManager memory leak

This commit is contained in:
fuxiao 2015-10-09 10:07:26 +08:00
parent cdf6fa8a54
commit be4724ef47
1 changed files with 5 additions and 0 deletions

View File

@ -450,6 +450,11 @@ void ActionManager::update(float dt)
{
deleteHashElement(_currentTarget);
}
//if some node refrence 'target', it's refrence count >= 2 (issues #14050)
else if (_currentTarget->target->getReferenceCount() == 1)
{
deleteHashElement(_currentTarget);
}
}
// issue #635