From 52e5b513ed9dc143c967c733423fe751e1b663d1 Mon Sep 17 00:00:00 2001 From: kwolekr Date: Sat, 31 Oct 2015 16:31:43 -0400 Subject: Fix Lua scripting synchronization For several years now, the lua script lock has been completely broken. This commit fixes the main issue (creation of a temporary rather than scoped object), and fixes a subsequent deadlock issue caused by nested script API calls by adding support for recursive mutexes. --- src/threading/mutex.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/threading/mutex.h') diff --git a/src/threading/mutex.h b/src/threading/mutex.h index f1a4882b7..62a482787 100644 --- a/src/threading/mutex.h +++ b/src/threading/mutex.h @@ -49,7 +49,7 @@ DEALINGS IN THE SOFTWARE. class Mutex { public: - Mutex(); + Mutex(bool recursive=false); ~Mutex(); void lock(); void unlock(); -- cgit v1.2.3