flutter-webrtc / callkeep

iOS CallKit and Android ConnectionService for Flutter
MIT License
138 stars 150 forks source link

Crash on iOS #66

Open Bubu opened 3 years ago

Bubu commented 3 years ago

Hey,

we get an occasional crash in our iOS app that points to the callkeep plugin, this is the stracktrace we get in the developer console:

Last Exception Backtrace:
0   CoreFoundation                  0x18e1499d8 __exceptionPreprocess + 216 (NSException.m:199)
1   libobjc.A.dylib                 0x1a24ccb54 objc_exception_throw + 56 (objc-exception.mm:565)
2   CoreFoundation                  0x18e04c4d0 +[NSException raise:format:] + 108 (NSException.m:155)
3   CallKit                         0x1ac380b44 -[CXProviderConfiguration initWithLocalizedName:] + 120 (CXProviderConfiguration.m:48)
4   callkeep                        0x1055bf754 +[CallKeep getProviderConfiguration:] + 116 (CallKeep.m:583)
5   callkeep                        0x1055bd21c +[CallKeep initCallKitProvider] + 156 (CallKeep.m:171)
6   callkeep                        0x1055bf118 +[CallKeep reportNewIncomingCall:handle:handleType:hasVideo:localizedCallerName:fromPushKit:payload:withCompletionHandler:] + 424 (CallKeep.m:518)
7   callkeep                        0x1055bdc08 -[CallKeep displayIncomingCall:handle:handleType:hasVideo:localizedCallerName:] + 124 (CallKeep.m:287)
8   callkeep                        0x1055bc9b0 -[CallKeep handleMethodCall:result:] + 460 (CallKeep.m:87)
9   callkeep                        0x1055c0ff4 -[FlutterCallkeepPlugin handleMethodCall:result:] + 72 (FlutterCallkeepPlugin.m:59)
10  Flutter                         0x105f08e60 0x105948000 + 6032992
11  Flutter                         0x1059800d8 0x105948000 + 229592
12  Flutter                         0x105c7cf8c 0x105948000 + 3362700
13  Flutter                         0x105c1dd94 0x105948000 + 2973076
14  Flutter                         0x105c1fbf4 0x105948000 + 2980852
15  CoreFoundation                  0x18e0ca3e0 __CFRUNLOOP_IS_CALLING_OUT_TO_A_TIMER_CALLBACK_FUNCTION__ + 28 (CFRunLoop.c:1807)
16  CoreFoundation                  0x18e0c9fe4 __CFRunLoopDoTimer + 1004 (CFRunLoop.c:2415)
17  CoreFoundation                  0x18e0c94c4 __CFRunLoopDoTimers + 324 (CFRunLoop.c:2575)
18  CoreFoundation                  0x18e0c3850 __CFRunLoopRun + 1912 (CFRunLoop.c:3090)
19  CoreFoundation                  0x18e0c2ba0 CFRunLoopRunSpecific + 572 (CFRunLoop.c:3242)
20  GraphicsServices                0x1a4e28598 GSEventRunModal + 160 (GSEvent.c:2259)
21  UIKitCore                       0x1909b42f4 -[UIApplication _run] + 1052 (UIApplication.m:3253)
22  UIKitCore                       0x1909b9874 UIApplicationMain + 164 (UIApplication.m:4707)
23  Runner                          0x104694b84 main + 64 (AppDelegate.swift:6)
24  libdyld.dylib                   0x18dda1568 start + 4

This happens on app startup and seems unrelated to any call functionality. Any ideas what might be going on?

cloudwebrtc commented 3 years ago

Please try this commit https://github.com/flutter-webrtc/callkeep/commit/cc57761da91c6e8814156c2e1f3110b2bd8b0910