iOS 之各种Crash

1.*** Terminating app due to uncaught exception 'CALayerInvalidGeometry', reason: 'CALayer position contains NaN: [nan 135]'


2.-[_NSInlineData objectForKeyedSubscript:]: unrecognized selector sent to instance 0x13dabd600

原因:

By default AFNetworking will parse your JSON for you. AFHTTPResponseSerializer will just give you an NSData object as responseObject

解决:
remove:
manager.responseSerializer=[AFHTTPResponseSerializer serializer];
or
manager.responseSerializer.acceptableContentTypes = [NSSet setWithObjects:@"text/plain", @"text/html",@"application/javascript",@"application/json", nil];

stackoverflow链接

3.ImageIO: CreateMetadataFromXMPBufferInternal Threw error #201 (XML parsing failure)

方案链接

posted @ 2016-10-25 09:01  YaoJinye  阅读(516)  评论(0编辑  收藏  举报