From 3262976401bb550e8d77e8d2346b39f682219248 Mon Sep 17 00:00:00 2001 From: wheremyfoodat <44909372+wheremyfoodat@users.noreply.github.com> Date: Fri, 29 Sep 2023 18:19:01 +0300 Subject: [PATCH] Unlock mutex in constructor --- src/Lib/Threads.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/Lib/Threads.cpp b/src/Lib/Threads.cpp index 1da287d30..4bf61aa2d 100644 --- a/src/Lib/Threads.cpp +++ b/src/Lib/Threads.cpp @@ -52,7 +52,10 @@ int Lib::Thread::GetThreadIdUnique() { return tid; } -Lib::Mutex::Mutex() { m_mutex = new MutexStructInternal(); } +Lib::Mutex::Mutex() { + m_mutex = new MutexStructInternal(); + UnlockMutex(); +} Lib::Mutex::~Mutex() { delete m_mutex; }