You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
-[__NSCFString objectForKey:]: unrecognized selector sent to instance 0x148027b50
How come does [self add_cache] could be an NSString? Do you have any idea how to prevent this crash to happen ? Should we re-think the way _imageCache is initialized?
in a background thread, could that be the reason why the crash is random? (I can't seem to reproduce it reliably). Should I make the call only from the main thread and would that be enough to never encounter the crash again?
The text was updated successfully, but these errors were encountered:
Thanks for reporting the issue. This problem has never happened to me before. However, I guess that the current implementation is not thread safe when creating the NSCache instance.
Therefore, I've replaced the current implementation for a dispatch_once block. This should prevent any thread issue when accessing the +add_cache method.
You will find the changes in version 2.1.1 (already available in Cocoa Pods).
For now I will close the issue, however if the problem reappears, please let me know and I'll reopen it.
Hello,
First of all thank you for the nice library!
I have got an app that use it in production but unfortunately Fabric reports many crashes from users at line 413:
with the exception:
How come does
[self add_cache]
could be an NSString? Do you have any idea how to prevent this crash to happen ? Should we re-think the way_imageCache
is initialized?To give you more insight, I make use of
in a background thread, could that be the reason why the crash is random? (I can't seem to reproduce it reliably). Should I make the call only from the main thread and would that be enough to never encounter the crash again?
The text was updated successfully, but these errors were encountered: