AFNetworking/AFNetworking — pull request #1182 by pgaspar (2013-07-30 15:32:53+00:00)
Title: UIImageView+AFNetworking with high resolution images crashing the app

I am building an app with user defined content that may, in some circumstances, have images that are yet to be resized.

While testing, I found an image that was crashing my app while running on my iPad Mini. Some discussion later ([over at stackoverflow](http://stackoverflow.com/questions/17937643/uiimageviewafnetworking-on-device-memory-problems-for-large-images-leak)) it was apparent that the problem was the image had 12150×6075 pixels.

Should AFNetworking automatically discard huge images like this? Could it be a configuration of some sort?

For my own app I implemented the hotfix you see in the pull request. This is obviously not what you would implement but at least it shows it's possible and it may help someone in the same situation.