cocos2d-1.0.1-x-0.12.0 CCSpawn CCObject->retain() assert ?

Hi,

I just update to 0.12.0 and I found there is an assert happened to my CCSpawn().

Here is the sample code to reproduce and it’s fine at 0.11.0 !

CCAnimation* openAnimation = CCAnimation::animation();
openAnimation~~>setDelay;
openAnimation~~>addFrame(CCSpriteFrameCache::sharedSpriteFrameCache()>spriteFrameByName);
openAnimation
>addFrame(CCSpriteFrameCache::sharedSpriteFrameCache()>spriteFrameByName);
openAnimation
>addFrame(CCSpriteFrameCache::sharedSpriteFrameCache()>spriteFrameByName);
this
>runAction(CCSequence::actions(
CCSpawn::actions(CCAnimate::actionWithAnimation(openAnimation, true),
CCScaleTo::actionWithDuration(0.3f, 1.1f)),
CCCallFuncN::actionWithTarget(this, callfuncN_selector(BoxSprite::afterTouch)),
NULL));

The assert will occurred at CCObject.cpp

void CCObject::retain(void)
{
CCAssert(m_uReference > 0, “reference count should greater than 0”);

++m_uReference;
}

I use a work-around to get it worked by splitting the CCSpawn into two actions.

this~~>runAction);
this~~>runAction(CCSequence::actions( CCScaleTo::actionWithDuration(0.3f, 1.1f),
CCCallFuncN::actionWithTarget(this, callfuncN_selector(BoxSprite::afterTouch)),
NULL));

If it’s my fault to use CCSpawn with wrong steps, please let me know.

Thank you.

I don’t find any fault of the codes.
Could you attach a demo to help us to reproduce it?