1 2015-09-28 17:32:03.098 每天送[2079:1664555] This application is modifying the autolayout engine from a background thread, which can lead to engine corruption and weird crashes. This will cause an exception in a future release. 2 Stack:( 3 0 CoreFoundation 0x0000000183320f74 <redacted> + 148 4 1 libobjc.A.dylib 0x0000000197f13f80 objc_exception_throw + 56 5 2 CoreFoundation 0x0000000183320ea4 <redacted> + 0 6 3 Foundation 0x000000018433a5d8 <redacted> + 88 7 4 Foundation 0x00000001841bca1c <redacted> + 36 8 5 UIKit 0x0000000188871a34 <redacted> + 532 9 6 UIKit 0x0000000188b798e0 <redacted> + 228 10 7 UIKit 0x0000000188870458 <redacted> + 412 11 8 §©Â§©ÈÄÅ 0x0000000100241fc4 -[UIViewController(Toast) hideLoading] + 84 12 9 §©Â§©ÈÄÅ 0x00000001001ef4c4 __51-[FudaiPayViewController wxPayWithOrderName:price:]_block_invoke + 380 13 10 libdispatch.dylib 0x00000001006a9d70 _dispatch_call_block_and_release + 24 14 11 libdispatch.dylib 0x00000001006a9d30 _dispatch_client_callout + 16 15 12 libdispatch.dylib 0x00000001006b8f38 _dispatch_root_queue_drain + 2344 16 13 libdispatch.dylib 0x00000001006b8600 _dispatch_worker_thread3 + 132 17 14 libsystem_pthread.dylib 0x0000000198921478 _pthread_wqthread + 1092 18 15 libsystem_pthread.dylib 0x0000000198921028 start_wqthread + 4 19 )
調試微信支付時,發現偶爾會有一次崩潰的問題,跟蹤,發現調試模式會報這個錯誤,可是正常模式會直接crash,注意看紅色的那行,由於代碼是在http的回包block裏執行的,應該就是所謂後臺執行了,修改掉微信
dispatch_async(dispatch_get_main_queue(), ^{
[weakSelf hideLoading];
});