c++ - Automatically Relaunch Application On Crash? -
on android, i'm running application using ndk runs series of tests in c++. if ever 1 of tests fails, means crash, i'd application relaunch , start @ next test.
i wish use exceptions ndk doesn't support them.
is possible?
- why application have crash? why not catch exception being thrown? compiler doesn't enforce add try..catch block, runtimeexceptions might still thrown.
- you can use thread.setdefaultuncaughtexceptionhandler. note must called per thread.
- if, reason, solutions above not suitable you, create background service acts watchdog timer.
edit: check this link: custom version of ndk supports c++ exceptions. found in this thread.
Comments
Post a Comment