twilio / cocoapod-specs

https://www.twilio.com/
10 stars 15 forks source link

Crash on CallKit's Audio Session Activated & Deactivated #111

Closed archonitex closed 6 years ago

archonitex commented 6 years ago

We're seeing crashes on Audio Session activated & Deactivated. Happens on audioSessionDeactivated & startAudio, seems to be the same issue on both function calls.

Only seeing this on iOS 10.x.x, iPhones & iPads

BUG IN CLIENT OF LIBDISPATCH: dispatch_barrier_sync called on queue already owned by current thread

Crashed: com.apple.main-thread
0  libdispatch.dylib              0x1c1b8c68 _dispatch_barrier_sync_f_slow + 517
1  TwilioVoice                    0x11c2a0d -[TVODispatchQueue dispatchSyncOnQueue:withBlock:] + 98
2  TwilioVoice                    0x11c2a0d -[TVODispatchQueue dispatchSyncOnQueue:withBlock:] + 98
3  TwilioVoice                    0x11d6bb5 -[TwilioVoice startAudio] + 372
4  Hushed                         0x20a811 -[TwilioVOIPClient startAudioDevice] (TwilioVOIPClient.m:79)
5  Hushed                         0x288a3d -[CallKitProvider provider:didActivateAudioSession:] (CallKitProvider.m:456)
6  CallKit                        0x337d184f __57-[CXProvider handleAudioSessionActivationStateChangedTo:]_block_invoke_2 + 672
7  libdispatch.dylib              0x1c1a9797 _dispatch_call_block_and_release + 10
8  libdispatch.dylib              0x1c1a9783 _dispatch_client_callout + 22
9  libdispatch.dylib              0x1c1add05 _dispatch_main_queue_callback_4CF + 902
10 CoreFoundation                 0x1ca97d69 __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 8
11 CoreFoundation                 0x1ca95e19 __CFRunLoopRun + 848
12 CoreFoundation                 0x1c9e91af CFRunLoopRunSpecific + 470
13 CoreFoundation                 0x1c9e8fd1 CFRunLoopRunInMode + 104
14 GraphicsServices               0x1e193b41 GSEventRunModal + 80
15 UIKit                          0x21d6ae13 UIApplicationMain + 150
16 Hushed                         0xa39c9 main (main.m:35)
17 libdyld.dylib                  0x1c1d64eb start + 2
Crashed: com.apple.main-thread
0  libdispatch.dylib              0x1af18c68 _dispatch_barrier_sync_f_slow + 517
1  TwilioVoice                    0x115f3ef -[TVODispatchQueue dispatchSyncOnQueue:withBlock:] + 102
2  TwilioVoice                    0x115f3ef -[TVODispatchQueue dispatchSyncOnQueue:withBlock:] + 102
3  TwilioVoice                    0x1173961 -[TwilioVoice audioSessionDeactivated] + 372
4  Hushed                         0x1a3be5 -[TwilioVOIPClient audioSessionDeactivated] (TwilioVOIPClient.m:75)
5  Hushed                         0x221eeb -[CallKitProvider provider:didDeactivateAudioSession:] (CallKitProvider.m:467)
6  CallKit                        0x3254184f __57-[CXProvider handleAudioSessionActivationStateChangedTo:]_block_invoke_2 + 672
7  libdispatch.dylib              0x1af09797 _dispatch_call_block_and_release + 10
8  libdispatch.dylib              0x1af09783 _dispatch_client_callout + 22
9  libdispatch.dylib              0x1af0dd05 _dispatch_main_queue_callback_4CF + 902
10 CoreFoundation                 0x1b7f7d69 __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 8
11 CoreFoundation                 0x1b7f5e19 __CFRunLoopRun + 848
12 CoreFoundation                 0x1b7491af CFRunLoopRunSpecific + 470
13 CoreFoundation                 0x1b748fd1 CFRunLoopRunInMode + 104
14 GraphicsServices               0x1cef3b41 GSEventRunModal + 80
15 UIKit                          0x20ad1a53 UIApplicationMain + 150
16 Hushed                         0x41409 main (main.m:35)
17 libdyld.dylib                  0x1af364eb start + 2

If I can provide additional information let me know how I can help

bobiechen-twilio commented 6 years ago

Hi @senatorsfc

Thanks for reporting this. Though we've never seen this during our development and validation but we did get another support ticket reporting the same crash, just that the user is seeing this with beta15.

I've opened another ticket in the ObjC quickstart repo and will be closing this one. We've pulled in the task for the next week and I'll give my findings and updates in the issue. Please feel free to follow up there.

bobie

bobiechen-twilio commented 6 years ago

Closing this one and follow up in the Voice quickstart repo. https://github.com/twilio/voice-quickstart-objc/issues/62