Ios 相机随机崩溃

Ios 相机随机崩溃,ios,iphone,ios-camera,Ios,Iphone,Ios Camera,我的应用程序在99%的时间内运行良好,但有1%在打开相机后崩溃,我们得到了一个随机崩溃。这是Crashlytics的stacktrace: Crashed: com.apple.camera.avcapturesession 0 libobjc.A.dylib 0x194d8fbd0 objc_msgSend + 16 1 UIKit 0x1890df21c -[UIViewAnimationState anim

我的应用程序在99%的时间内运行良好,但有1%在打开相机后崩溃,我们得到了一个随机崩溃。这是Crashlytics的stacktrace:

Crashed: com.apple.camera.avcapturesession
0  libobjc.A.dylib                0x194d8fbd0 objc_msgSend + 16
1  UIKit                          0x1890df21c -[UIViewAnimationState animationForLayer:forKey:forView:] + 712
2  UIKit                          0x188e55724 -[UIViewAnimationState actionForLayer:forKey:forView:] + 44
3  UIKit                          0x188e19f44 -[UIView(CALayerDelegate) actionForLayer:forKey:] + 140
4  QuartzCore                     0x188774e88 -[CALayer actionForKey:] + 104
5  QuartzCore                     0x18876a86c actionForKey(CALayer*, CA::Transaction*, NSString*) + 100
6  QuartzCore                     0x18876a6d8 CA::Layer::begin_change(CA::Transaction*, unsigned int, objc_object*&) + 176
7  QuartzCore                     0x18876d6a0 CA::Layer::setter(unsigned int, _CAValueType, void const*) + 156
8  QuartzCore                     0x188774e14 -[CALayer setOpacity:] + 48
9  UIKit                          0x188e19a5c -[UIView(Rendering) setAlpha:] + 104
10 corporate                      0x1005a3e5c -[GSDK_GTMReadMonitorInputStream .cxx_destruct]
11 corporate                      0x1005a4398 -[GSDK_GTMReadMonitorInputStream .cxx_destruct]
12 CoreFoundation                 0x184614ae4 __CFNOTIFICATIONCENTER_IS_CALLING_OUT_TO_AN_OBSERVER__ + 20
13 CoreFoundation                 0x184553220 _CFXNotificationPost + 2060
14 Foundation                     0x185452cc0 -[NSNotificationCenter postNotificationName:object:userInfo:] + 72
15 AVFoundation                   0x182efd9c4 -[AVCaptureSession _setRunning:] + 312
16 CameraKit                      0x18aac1adc __38-[CAMCaptureController _startPreview:]_block_invoke829
17 libdispatch.dylib              0x1953c13ac _dispatch_call_block_and_release + 24
18 libdispatch.dylib              0x1953c136c _dispatch_client_callout + 16
19 libdispatch.dylib              0x1953cb4c0 _dispatch_queue_drain + 1216
20 libdispatch.dylib              0x1953c4474 _dispatch_queue_invoke + 132
21 libdispatch.dylib              0x1953cd224 _dispatch_root_queue_drain + 664
22 libdispatch.dylib              0x1953ce75c _dispatch_worker_thread3 + 108
23 libsystem_pthread.dylib        0x19559d2e4 _pthread_wqthread + 816
24 libsystem_pthread.dylib        0x19559cfa8 start_wqthread + 4
我不完全明白这次崩溃是从哪里来的,但我发现我可能与
GoogleNetworkingUtilities


你确定你没有做任何会影响后台线程中任何UI元素的事情吗?

如果你使用的是iOS 10,你需要在你的Info.plist文件中添加
隐私-摄像头使用说明

我没有使用iOS 10,这是在iOS 9上发生的。