about summary refs log tree commit diff stats
path: root/src/libtools
diff options
context:
space:
mode:
authorptitSeb <sebastien.chev@gmail.com>2024-12-05 11:12:02 +0100
committerptitSeb <sebastien.chev@gmail.com>2024-12-05 11:12:02 +0100
commita30433ea120ba502045782296db85bb27f643d6b (patch)
treeb16692e1b2de15b9b5a3e10fa19ebca4bcb36cc3 /src/libtools
parent6f7b462d53e5a573318a343cf3db0b322e587855 (diff)
downloadbox64-a30433ea120ba502045782296db85bb27f643d6b.tar.gz
box64-a30433ea120ba502045782296db85bb27f643d6b.zip
[NON4KPAGE] Some more adjustments for non-4Kpagesize system (should help #2110)
Diffstat (limited to 'src/libtools')
-rw-r--r--src/libtools/signals.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/libtools/signals.c b/src/libtools/signals.c
index dd98e4c6..db4a5709 100644
--- a/src/libtools/signals.c
+++ b/src/libtools/signals.c
@@ -1401,10 +1401,6 @@ void my_box64signalhandler(int32_t sig, siginfo_t* info, void * ucntx)
         signal_jmpbuf_active = 0;
         longjmp(SIG_JMPBUF, 1);
     }
-    if((sig==SIGSEGV || sig==SIGBUS) && box64_quit) {
-        printf_log(LOG_INFO, "Sigfault/Segbus while quitting, exiting silently\n");
-        _exit(box64_exit_code);    // Hack, segfault while quiting, exit silently
-    }
     ucontext_t *p = (ucontext_t *)ucntx;
     void* addr = (void*)info->si_addr;  // address that triggered the issue
     void* rsp = NULL;
@@ -1614,6 +1610,10 @@ dynarec_log(/*LOG_DEBUG*/LOG_INFO, "Repeated SIGSEGV with Access error on %p for
 #else
     void* db = NULL;
 #endif
+    if((sig==SIGSEGV || sig==SIGBUS) && box64_quit) {
+        printf_log(LOG_INFO, "Sigfault/Segbus while quitting, exiting silently\n");
+        _exit(box64_exit_code);    // Hack, segfault while quiting, exit silently
+    }
     static int old_code = -1;
     static void* old_pc = 0;
     static void* old_addr = 0;