iphone - Closing an app in the background -


Suppose I have an iOS app that is actually running in the background (for one of many legal reasons, such as background audio, requested time, etc.). What could happen if the OS shut down this app instead of running or suspending this race? How can I avoid them? How can I use the public API (inside this app) How can I trigger?

Your app can be killed, it uses too much memory, if it EndBackgroundTask: , the timeout handler ( beginBackgroundTaskWithExpirationHandler: is called while specifying), if the user hits it clearly, if the app throws an exception , Call exit , triggers an EXC_BAD_ACCESS or other signal, and so on. There are probably other reasons too.

To avoid these, do not use too much memory, call Endbacker Task: Create an app that will not want the user want kill, and the exception Do not throw, call exit , use invalid storage locations, and so on.

There is no way to do this so that the user "" For others, you can allocate multiple memory, refuse to call endBackgroundTask: , [NSException raise: ... format: ...] , Call exit , or create and follow the random garbage signals. You probably should not do any of these, though.

Comments

Popular posts from this blog

qt - switch/case statement in C++ with a QString type -

python - sqlite3.OperationalError: near "REFERENCES": syntax error - foreign key creating -

Python's equivalent for Ruby's define_method? -