!1027 Panic支持ExcHook

Merge pull request !1027 from zhangdengyu/supportPanicHook
This commit is contained in:
openharmony_ci 2023-02-22 06:18:48 +00:00 committed by Gitee
commit 4431b587f8
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
2 changed files with 2 additions and 0 deletions

View File

@ -114,6 +114,7 @@ LITE_OS_SEC_TEXT_INIT VOID LOS_Panic(const CHAR *fmt, ...)
va_start(ap, fmt);
PRINT_ERR(fmt, ap);
va_end(ap);
OsDoExcHook(EXC_PANIC);
#if (LOSCFG_BACKTRACE_TYPE != 0)
LOS_BackTrace();
#endif

View File

@ -74,6 +74,7 @@ typedef struct {
typedef enum {
EXC_REBOOT,
EXC_ASSERT,
EXC_PANIC,
EXC_STACKOVERFLOW,
EXC_INTERRUPT,
EXC_TYPE_END