0

Trying to set an image data

NSData *thumbnailData = UIImageJPEGRepresentation(place.thumbnail, 0.8);
            [placeDict setObject:thumbnailData forKey:thumbnail];

And getting error:

Could not messagepack object: External Data Reference: <self = 0xbba24f0 ; path = nil ; length = 557>
Kazuki Ohta
  • 1,441
  • 17
  • 17
Shmidt
  • 16,436
  • 18
  • 88
  • 136

1 Answers1

1

Are you sure that you recive this error after this lines of code? Use this code to be quite sure that your program have/not have errors in this part of code:

NSLog((@"%s [Line %d] "), __PRETTY_FUNCTION__, __LINE__);
NSData *thumbnailData = UIImageJPEGRepresentation(place.thumbnail, 0.8);
NSLog((@"%s [Line %d] "), __PRETTY_FUNCTION__, __LINE__);
placeDict setObject:thumbnailData forKey:thumbnail];
NSLog((@"%s [Line %d] "), __PRETTY_FUNCTION__, __LINE__);
Mikhail Viceman
  • 604
  • 3
  • 9