From 07ec3d2f5229c54a44b2d855bdd689cbdafcf549 Mon Sep 17 00:00:00 2001 From: Doug Date: Mon, 5 Jul 2021 19:19:51 +0100 Subject: [PATCH 1/2] Fix crash when running on macOS with Apple Silicon. --- Riot/Modules/Application/LegacyAppDelegate.m | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Riot/Modules/Application/LegacyAppDelegate.m b/Riot/Modules/Application/LegacyAppDelegate.m index ff81e5f57..32010f9bb 100644 --- a/Riot/Modules/Application/LegacyAppDelegate.m +++ b/Riot/Modules/Application/LegacyAppDelegate.m @@ -351,6 +351,9 @@ NSString *const AppDelegateUniversalLinkDidChangeNotification = @"AppDelegateUni NSURL *messageSoundURL = [[NSBundle mainBundle] URLForResource:@"message" withExtension:@"caf"]; AudioServicesCreateSystemSoundID((__bridge CFURLRef)messageSoundURL, &_messageSound); + // Set app info now as Mac (Designed for iPad) accesses it before didFinishLaunching is called + self.appInfo = AppInfo.current; + MXLogDebug(@"[AppDelegate] willFinishLaunchingWithOptions: Done"); return YES; @@ -371,8 +374,6 @@ NSString *const AppDelegateUniversalLinkDidChangeNotification = @"AppDelegateUni _configuration = [AppConfiguration new]; - self.appInfo = AppInfo.current; - // Log app information NSString *appDisplayName = self.appInfo.displayName; NSString* appVersion = self.appVersion; From ebcb3e7124c9b7b953f4a607f046cc279333fb2c Mon Sep 17 00:00:00 2001 From: Doug Date: Mon, 5 Jul 2021 19:21:16 +0100 Subject: [PATCH 2/2] Update CHANGES.rst. --- CHANGES.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGES.rst b/CHANGES.rst index 2e72d9c8e..e6b12a975 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -8,7 +8,7 @@ Changes to be released in next version * 🐛 Bugfix - * + * Fix crash on Apple Silicon Macs. ⚠️ API Changes *