diff options
author | Michel Dänzer <michel.daenzer@amd.com> | 2017-04-26 18:31:08 +0900 |
---|---|---|
committer | Adam Jackson <ajax@redhat.com> | 2017-09-25 15:34:10 -0400 |
commit | b3de3ebcf450fd4ab1543dd2f133e45e9c0b9e7e (patch) | |
tree | 344b0b12ecc5d057b8a4d8bfdd230e817d286275 /hw | |
parent | e59a32c897c9f093f54ce4b695e9aff1ba20bda2 (diff) |
os: Handle SIGABRT
Without this, assertion failures can make life hard for users and those
trying to help them.
v2:
* Change commit log wording slightly to "can make life hard", since
apparently e.g. logind can alleviate that somewhat.
* Set default handler for SIGABRT in
hw/xfree86/common/xf86Init.c:InstallSignalHandlers() and
hw/xquartz/quartz.c:QuartzInitOutput() (Eric Anholt)
Reviewed-by: Eric Anholt <eric@anholt.net>
Signed-off-by: Michel Dänzer <michel.daenzer@amd.com>
(cherry picked from commit 27a6b9f7c84c914d0f5909ec1069d72f5035bc04)
Diffstat (limited to 'hw')
-rw-r--r-- | hw/xfree86/common/xf86Init.c | 1 | ||||
-rw-r--r-- | hw/xquartz/quartz.c | 1 |
2 files changed, 2 insertions, 0 deletions
diff --git a/hw/xfree86/common/xf86Init.c b/hw/xfree86/common/xf86Init.c index a544b6543..d59c224d5 100644 --- a/hw/xfree86/common/xf86Init.c +++ b/hw/xfree86/common/xf86Init.c @@ -309,6 +309,7 @@ InstallSignalHandlers(void) } else { OsSignal(SIGSEGV, SIG_DFL); + OsSignal(SIGABRT, SIG_DFL); OsSignal(SIGILL, SIG_DFL); #ifdef SIGEMT OsSignal(SIGEMT, SIG_DFL); diff --git a/hw/xquartz/quartz.c b/hw/xquartz/quartz.c index c8b6f966d..c8ea3bf8b 100644 --- a/hw/xquartz/quartz.c +++ b/hw/xquartz/quartz.c @@ -178,6 +178,7 @@ QuartzInitOutput(int argc, { /* For XQuartz, we want to just use the default signal handler to work better with CrashTracer */ signal(SIGSEGV, SIG_DFL); + signal(SIGABRT, SIG_DFL); signal(SIGILL, SIG_DFL); #ifdef SIGEMT signal(SIGEMT, SIG_DFL); |