diff options
| author | ptitSeb <sebastien.chev@gmail.com> | 2025-07-23 11:13:28 +0200 |
|---|---|---|
| committer | ptitSeb <sebastien.chev@gmail.com> | 2025-07-23 11:13:37 +0200 |
| commit | 49cc5eabcbcebdd6a67bfa32a82caf1723997d78 (patch) | |
| tree | 18789911b978ca0fa85a336f75cff117903c8a3f /src/libtools/threads.c | |
| parent | bf429a1dcfdaa960857f03a6f85e0dbf83e8b1e4 (diff) | |
| download | box64-49cc5eabcbcebdd6a67bfa32a82caf1723997d78.tar.gz box64-49cc5eabcbcebdd6a67bfa32a82caf1723997d78.zip | |
Some handling of case where signal numbers differs between native and x64 archs (not complete, missing sigset conversions)
Diffstat (limited to 'src/libtools/threads.c')
| -rw-r--r-- | src/libtools/threads.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/libtools/threads.c b/src/libtools/threads.c index 3ba83ba0..aa0cbe08 100644 --- a/src/libtools/threads.c +++ b/src/libtools/threads.c @@ -4,10 +4,10 @@ #include <stdio.h> #include <stdlib.h> #include <pthread.h> -#include <signal.h> #include <errno.h> #include <setjmp.h> +#include "x64_signals.h" #include "os.h" #include "debug.h" #include "box64context.h" @@ -834,6 +834,7 @@ EXPORT int my_pthread_setaffinity_np_old(x64emu_t* emu, pthread_t thread, void* EXPORT int my_pthread_kill(x64emu_t* emu, void* thread, int sig) { + sig = signal_from_x64(sig); // should ESCHR result be filtered, as this is expected to be the 2.34 behaviour? (void)emu; // check for old "is everything ok?" @@ -844,6 +845,7 @@ EXPORT int my_pthread_kill(x64emu_t* emu, void* thread, int sig) EXPORT int my_pthread_kill_old(x64emu_t* emu, void* thread, int sig) { + sig = signal_from_x64(sig); // check for old "is everything ok?" if((thread==NULL) && (sig==0)) return real_phtread_kill_old(pthread_self(), 0); |