Merge "debuggerd: fix CrasherTest.seccomp_crash_oom." am: 74bf81443f

am: 10537510a8

Change-Id: I1266f8c5763032719f2f445d5eb6e764ca21a899
This commit is contained in:
Josh Gao 2018-05-18 19:24:27 -07:00 committed by android-build-merger
commit dfb5b4b1ad

View file

@ -304,7 +304,16 @@ static void crash_handler(siginfo_t* info, ucontext_t* ucontext, void* abort_mes
crash_mutex.lock();
if (lock_count++ > 0) {
async_safe_format_log(ANDROID_LOG_ERROR, "libc", "recursed signal handler call, exiting");
async_safe_format_log(ANDROID_LOG_ERROR, "libc", "recursed signal handler call, aborting");
signal(SIGABRT, SIG_DFL);
raise(SIGABRT);
sigset_t sigset;
sigemptyset(&sigset);
sigaddset(&sigset, SIGABRT);
sigprocmask(SIG_UNBLOCK, &sigset, nullptr);
// Just in case...
async_safe_format_log(ANDROID_LOG_ERROR, "libc", "abort didn't exit, exiting");
_exit(1);
}