diff --git a/src/TLuaEngine.cpp b/src/TLuaEngine.cpp index 6881cfc..d814a22 100644 --- a/src/TLuaEngine.cpp +++ b/src/TLuaEngine.cpp @@ -64,8 +64,9 @@ void TLuaEngine::operator()() { if (Waited > 250) { // FIXME: This should *eventually* timeout. // beammp_lua_error(Res->Function + " in " + Res->StateId + " took >1s to respond, not printing possible errors"); - std::unique_lock Lock(mResultsToCheckMutex); + Lock.lock(); mResultsToCheck.push(Res); + Lock.unlock(); break; } }