-
Notifications
You must be signed in to change notification settings - Fork 915
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
iOS8 __ModelToJSONObjectRecursive_block_invoke.444 (NSObject+YYModel.m:) Crash #303
Comments
解决了嘛? |
什么问题导致的? 我也遇见了 |
可以试试 把ModelToJSONObjectRecursive 方法里的for in 改成for -I ,for in在遍历数组是被修改,会崩溃,for I 不会(for I = 0 ; I < n ; I ++)) |
@wangbo1185742894 你试过之后解决了吗 |
忘写 |
建议检查一下 model 的属性,看看是否存在使用 assign 修饰的 NSString 或者其他继承自 NSObject 的 Class。我复现了此崩溃,根源便在于使用 assign 修饰了 NSString。 |
出错堆栈
0 libobjc.A.dylib
objc_retain + 20
1 WoZaiJia
__ModelToJSONObjectRecursive_block_invoke.444 (NSObject+YYModel.m:1222)
2 CoreFoundation
___65-[__NSDictionaryM enumerateKeysAndObjectsWithOptions:usingBlock:]_block_invoke + 124
3 CoreFoundation
-[__NSDictionaryM enumerateKeysAndObjectsWithOptions:usingBlock:] + 204
4 WoZaiJia
ModelToJSONObjectRecursive (NSObject+YYModel.m:1276)
5 WoZaiJia
-[NSObject(YYModel) yy_modelToJSONObject] (NSObject+YYModel.m:0)
The text was updated successfully, but these errors were encountered: