From 43cb05e08889538f792b096da69e005890088c9d Mon Sep 17 00:00:00 2001 From: Sergey Stepanov Date: Sat, 8 Apr 2023 19:45:59 +0300 Subject: [PATCH] Remove unused OS signal handlers in C The idea is that we make just one OS signals handler on the C (CGO) side instead of Go and handle everything there from both, which is needed for proper termination process of multithreaded Libretro cores. But it leads to strange segfaults. --- pkg/worker/emulator/libretro/nanoarch.c | 7 ------- 1 file changed, 7 deletions(-) diff --git a/pkg/worker/emulator/libretro/nanoarch.c b/pkg/worker/emulator/libretro/nanoarch.c index 15e1440f..8a34c273 100644 --- a/pkg/worker/emulator/libretro/nanoarch.c +++ b/pkg/worker/emulator/libretro/nanoarch.c @@ -3,8 +3,6 @@ #include #include #include -//#include -//#include int initialized = 0; @@ -177,11 +175,6 @@ pthread_cond_t run_cv; pthread_mutex_t done_mutex; pthread_cond_t done_cv; -// hack: go hangs with run_loop if SIGINT signal, so we handle it here -//static void sig_handler(int _) { -// exit(0); -//} - void *run_loop(void *unused) { coreLog(RETRO_LOG_DEBUG, "UnLIBCo run loop start\n"); pthread_mutex_lock(&done_mutex);