cocos2d/cocos2d-iphone — comment on commit 5a16b6e8dbc17a833c58757c63ea78c5ca7101ac
File:  line 0
By Panajev:

Hey Riq,

I would change the setter as it could cause problems this way, if userData is pointing to the same object as userData_.

CCNode:284, inside the actual method...

if (retainUserData_ && userData_ != userData) {
[userData_ release];
}

retainUserData_ = retainData;
userData_ = userData;

if( retainUserData_ && userData_ != userData ) {
[userData_ retain];
}