The CocosBuilderTest example will leak layers when going into and out of the AnimationsTestLayer. This is because AnimationsTestLayer keeps a reference to CCBAnimationManager and CCBAnimationManager keeps a reference to AnimationsTestLayer. It’s a circular dependency. Neither class will get it’s destructor called because the reference count never drops.
Is this the correct place to report bugs and bug fixes? I never get a response to my threads and I want to make sure these are being seen.
Hey, I realize that you posted 25 days ago by now. But I can across this issue today as well when I was profiling my ios app for leaks. Here is what I did to resolve this problem. You are correct about the circular dependency and because of this neither destructor gets called what I end up doing is keeping a CCBAnimationManager member variable in the same class where I load my ccbi file and I manage this variable in that class. Here is an example:
Hey, I realize that you posted 25 days ago by now. But I can across this issue today as well when I was profiling my ios app for leaks. Here is what I did to resolve this problem. You are correct about the circular dependency and because of this neither destructor gets called what I end up doing is keeping a CCBAnimationManager member variable in the same class where I load my ccbi file and I manage this variable in that class. Here is an example:
>
[…]
>
and in the class’s destructor I call CC_SAFE_RELEASE_NULL:
[…]
>
So Franky, you might have already solved this issue yourself but maybe someone else will stumble on this same problem of circular dependency.