Unknown iOS crash

Crash was reported through crashlytics, so I have no specific scenario or description. Please find the crash log here:

Hi Barash,

Can you provide which version sdk report this issue?
We need this information to address the crash location.


Sorry, it is v4.4.55130.0712

Hi Barash~

I found you crash on “- (void)onMobileRTCLoginReturn:(NSInteger)returnValue”

MobileRTCAuthService *authService = [[MobileRTC sharedRTC] getAuthService];
authService.delegate = object;

This is an asynchronous callback.
please check the object is not dealloc.


I’m not sure I understand . This is my code:
func authSDK() {
if let authServices = MobileRTC.shared().getAuthService() {
authServices.delegate = self
authServices.clientKey = kSDKAppKey
authServices.clientSecret = kSDKAppSecret

func onMobileRTCAuthReturn(_ returnValue: MobileRTCAuthError) {
    print("onMobileRTCAuthReturn \(returnValue)");
    if returnValue != MobileRTCAuthError_Success {
        print("SDK authentication failed, error code: \(returnValue)")

What should I fix?

Hi Barash,

Thanks for your reply.
Do you set the authservices.delegate in Appdelegate?
You need care of the VC release, If you do this action in some other VC.
You can see the delegate declaration, we use the assign property for it.
@property (nullable, assign, nonatomic) id delegate;


Hi Jackie,

I’m calling the authSDK in AppDelegate in:
func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool

I’m calling this before calling authSDK:
MobileRTC.initialize(withDomain: kSDKDomain, enableLog: true)


Hi Idit,
Do you have any other information can be provide. Like crash numbers, device count, network status, statistic information?
We called this callback function asynced in main thread.


It happened 6 times in the last week - iOS 12 and 13 beta. Devices iPhone XR, iPhone 7 and iPhone 6s plus.
This is all the data I have from the Fabric web site. I don’t know what else I can give you…

It now also happens a lot in iOS 11. Please help, this is urgent

I now saw in your sample app that you call MobileRTC methods from different AppDelegate methods, like:
[[MobileRTC sharedRTC] appDidEnterBackgroud];
from - (void)applicationDidEnterBackground:(UIApplication *)application.

Is this a must? If I don’t call those methods, could that cause the crash?

[[MobileRTC sharedRTC] appDidEnterBackgroud];

this is must~~but that can’t cause crash.

Can you try in our sample code with your key and secret.

We found you crash in auth call back, We guessed that when auth callback came back, your object was destroyed.

Can you provide a sample code to help us reproduce the problem.

The problem is that the crash doesn’t happen every time :frowning:
And I sent all the relevant code in my previous answers. I ran your sample with my key and secret and it didn’t crash. But since my crash doesn’t happen every time, it is a little hard to catch.
Now that you gave me a clear explanation on what you think happens, I’ll investigate more and let you know.

ok~Let me know if you’re making any progress.
The best way is that you can provide a sample project to remove sensitive information to help us reproduce the problem


I found the issue. It was a very stupid mistake on my part. I wrote a utility class to handle the Zoom SDK, I referenced to that utility class without making sure it is retained. I solved it by making that class a singleton - it it the best solution for my scenario.

Thank you so much for all your help,

I’m glad you solved the problem.
Meeting Happiness.

1 Like