From 8a9d52ea23a03a8728ac3e49b6f60781773973c9 Mon Sep 17 00:00:00 2001 From: nakst <> Date: Wed, 2 Feb 2022 22:24:07 +0000 Subject: [PATCH] fix bugs --- util/script.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/util/script.c b/util/script.c index 2554f5b..f4319ef 100644 --- a/util/script.c +++ b/util/script.c @@ -4596,11 +4596,11 @@ int ExternalCharacterToByte(ExecutionContext *context, Value *returnValue) { void ExternalCoroutineDone(CoroutineState *coroutine) { #ifdef __linux__ - sem_post(&externalCoroutineSemaphore); pthread_mutex_lock(&externalCoroutineMutex); coroutine->nextExternalCoroutine = externalCoroutineUnblockedList; externalCoroutineUnblockedList = coroutine; pthread_mutex_unlock(&externalCoroutineMutex); + sem_post(&externalCoroutineSemaphore); #else (void) coroutine; #endif