I have several UIImagesView and I put them on a MutableArray. The MutableArray is retained. I add them also as a subview of a view.
After adding each UIImageViews on a view I release them... for example...
[myView addSubview:myImageView];
[myImageView release];
If I am not wrong, each imageView has now a retainCount of 2, because they are also stored on the MutableArray.
Now I release the view, so, each imageView retainCount drops to 1.
At some point I do:
myMutableArray = nil;
is it OK to do that? As the imageViews have yet a retainCount of 1, I am not sure if putting the array to nil, the array which were storing the imageViews will release the images... I suppose so, but I would like to hear from you masters!
will this leak?
thanks