adit
adit

Reputation: 33644

-[NSConcreteMutableData _isResizable]: issue with UIImage

I am getting the error below:

 -[NSConcreteData _isResizable]: unrecognized selector sent to instance 0x9954d30

on this code:

UIImage *cachedImage = [self cachedImageForUrl:self.imageSource];
if (cachedImage) {
    self.image = cachedImage;
}

any idea?

Upvotes: 0

Views: 1247

Answers (1)

Scott Corscadden
Scott Corscadden

Reputation: 2860

Are you using ARC? If not, this can happen when self.image doesn't correctly retain the cachedImage. When cachedImage gets dealloc'ed and self tries to access it, that memory might now point to random other classes (like NSConcreteData). How did you define the @property for UIImage *image?

Upvotes: 1

Related Questions