summaryrefslogtreecommitdiffstats
path: root/src/Generating/PrefabPiecePool.cpp
diff options
context:
space:
mode:
authorMattes D <github@xoft.cz>2017-01-13 10:31:05 +0100
committerGitHub <noreply@github.com>2017-01-13 10:31:05 +0100
commitfb0fc07579359c0055fc4ad92a005aa89dc9b817 (patch)
tree6a1555b1d714dc05617f23a41a1916993161c41a /src/Generating/PrefabPiecePool.cpp
parentLuaState: Fixed race condition in ref tracking. (#3529) (diff)
downloadcuberite-fb0fc07579359c0055fc4ad92a005aa89dc9b817.tar
cuberite-fb0fc07579359c0055fc4ad92a005aa89dc9b817.tar.gz
cuberite-fb0fc07579359c0055fc4ad92a005aa89dc9b817.tar.bz2
cuberite-fb0fc07579359c0055fc4ad92a005aa89dc9b817.tar.lz
cuberite-fb0fc07579359c0055fc4ad92a005aa89dc9b817.tar.xz
cuberite-fb0fc07579359c0055fc4ad92a005aa89dc9b817.tar.zst
cuberite-fb0fc07579359c0055fc4ad92a005aa89dc9b817.zip
Diffstat (limited to '')
-rw-r--r--src/Generating/PrefabPiecePool.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/Generating/PrefabPiecePool.cpp b/src/Generating/PrefabPiecePool.cpp
index d6c2c8819..407915e56 100644
--- a/src/Generating/PrefabPiecePool.cpp
+++ b/src/Generating/PrefabPiecePool.cpp
@@ -204,6 +204,7 @@ bool cPrefabPiecePool::LoadFromCubeset(const AString & a_Contents, const AString
// Load the file in the Lua interpreter:
cLuaState Lua(Printf("LoadablePiecePool %s", a_FileName.c_str()));
Lua.Create();
+ cLuaState::cLock lock(Lua);
if (!Lua.LoadString(a_Contents, a_FileName, a_LogWarnings))
{
// Reason for failure has already been logged in LoadFile()