App Killed by Sigkill When Changing Privacy Settings

App killed by SIGKILL when changing privacy settings

I think it is a bug or at least poorly documented and unexpected behavior. But it does not crash it is just forced to restart. You will get a SIGKILL message but no Crash log.

If you are a registered apple developer you can check their forums for discussions about this issue

  • https://devforums.apple.com/message/715855
  • https://devforums.apple.com/message/714178

I don't know of any way how to prevent this behavior but feel free to file a bug report with apple. It is rumored they use bug duplicates as a way of measuring the bug severity.
Maybe you can store your app state in order to restore it when it restarts.

Toggling Privacy settings will kill the app

the OS sends a SIGKILL which is not a crash - Apple session on privacy in iOS6 says:

  • If permissions changes, app is quit.
  • Background task expiration handler is called, if registered
  • iOS then kills the application.

WWDC 2012 Session Videos: Privacy Support in iOS and OS X

Expiration handler: beginBackgroundTaskWithExpirationHandler

There is no way around this I can see.

Watch App get killed while allowing/disallowing camera permission on iPhone App

Your app is not crashing its just forced to restart by WatchOS with new privacy settings. So when you change the any permission in iPhone then it means privacy policy changed, so app will be killed if its attached to debugger else it will relaunch. its happing on both Apple Watch and iPhone. if you change the permission in Apple Watch iOS app will restart. if you change the permission in iOS app Apple Watch app will be restart.

Also, Not only camera permission If the user at some point changes the Address Book, Calendars, Reminders, Camera, or Photos permissions, WatchOS app will SIGKILL the app when change App permission in iPhone. (it's default behaviour of iOS and WatchOS)

Please refer the below links

App killed by SIGKILL when changing privacy settings ,
https://developer.apple.com/forums/thread/64740,
App crashes in background while changing permission - swift,
App crashed in iOS 6 when user changes Contacts access permissions

App is forced to restart by iOS with new privacy settings

This is not a problem of your application. Its just the way apple designed iOS. iOS will terminate the application when user change certain permissions of it.

Actually you will get a SIGKILL message but no Crash log when toggling settings. In this situation even applicationWillTerminate not get called!

So the answer is you can't fix it.

Look at page 24 of this slide

Having app restart itself when it detects change to privacy settings

You misunderstand what is happening. Your app is not crashing (though it may appear so if you are running the app with the debugger).

When you switch to the Settings app (and your app is suspended in the background) and change the privacy settings, suspended apps are terminated. When you switch back to your app, it is simply started again. This is no different than your app being killed for any other reason.

It is up to you to code your app to handle this by restoring its previous state. The other app you talk about is simply returning the user to the previous state. Many apps do this. It has nothing to do with being killed due to privacy changes. The app would restore state when being killed for any reason.

App crash when change permission AddressBook in Settings

Your app is not crashing its just forced to restart by iOS with new privacy settings. So when you change the privacy policy, app will be killed if its attached to debugger else it will restart or relaunch.

Note : If the user at some point changes the Address Book, Calendars, Reminders, Camera, or Photos permissions, iOS will SIGKILL the app. (It's not crash it's default behaviour of iOS)

App crashes in background while changing permission - swift

Your app is not crashing its just forced to restart by iOS with new privacy settings. So when you change the camera permission then it means privacy policy changed, so app will be killed if its attached to debugger else it will relaunch.

Also, Not only camera permission If the user at some point changes the Address Book, Calendars, Reminders, Camera, or Photos permissions, iOS will SIGKILL the app. (it's default behaviour of iOS)



Related Topics



Leave a reply



Submit