about summary refs log tree commit diff stats
path: root/src/libtools
diff options
context:
space:
mode:
authorptitSeb <sebastien.chev@gmail.com>2023-02-26 09:47:15 +0100
committerptitSeb <sebastien.chev@gmail.com>2023-02-26 09:47:15 +0100
commitcc3237a77d21a13ce29d5768702704f84e3ee59b (patch)
tree5827bfc0ab3a9521660922fdf6749a68fdd9a678 /src/libtools
parentb65e02420f5ef1da5a6bb34b4d3020f4e38d6f91 (diff)
downloadbox64-cc3237a77d21a13ce29d5768702704f84e3ee59b.tar.gz
box64-cc3237a77d21a13ce29d5768702704f84e3ee59b.zip
[RK3588] Made Workaround also working on non-dynarec build (just in case...)
Diffstat (limited to 'src/libtools')
-rwxr-xr-xsrc/libtools/signals.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/libtools/signals.c b/src/libtools/signals.c
index cb237f7e..f8aa6cb8 100755
--- a/src/libtools/signals.c
+++ b/src/libtools/signals.c
@@ -847,12 +847,6 @@ void my_box64signalhandler(int32_t sig, siginfo_t* info, void * ucntx)
 #endif
     int Locks = unlockMutex();
     uint32_t prot = getProtection((uintptr_t)addr);
-#ifdef DYNAREC
-    if((Locks & is_dyndump_locked) && (sig==SIGSEGV) && current_helper) {
-        relockMutex(Locks);
-        CancelBlock64(0);
-        cancelFillBlock();  // Segfault inside a Fillblock, cancel it's creation...
-    }
     #ifdef RK3588
     // try to see if the si_code makes sense
     // the RK3588 tend to need a special Kernel that seems to have a weird behaviour sometimes
@@ -861,6 +855,12 @@ void my_box64signalhandler(int32_t sig, siginfo_t* info, void * ucntx)
         info->si_code = 2;
     }
     #endif
+#ifdef DYNAREC
+    if((Locks & is_dyndump_locked) && (sig==SIGSEGV) && current_helper) {
+        relockMutex(Locks);
+        CancelBlock64(0);
+        cancelFillBlock();  // Segfault inside a Fillblock, cancel it's creation...
+    }
     dynablock_t* db = NULL;
     int db_searched = 0;
     if ((sig==SIGSEGV) && (addr) && (info->si_code == SEGV_ACCERR) && (prot&PROT_DYNAREC)) {