From aae8accadd48c397ee9a714e6b114321c6208ab3 Mon Sep 17 00:00:00 2001
From: Karroffel <therzog@mail.de>
Date: Thu, 27 Jul 2017 14:55:07 +0200
Subject: [NativeScript] fix mutex double lock

In 3c53b35 a bug got introduced where a mutex gets locked twice
instead of locked and then unlocked.
This path fixes that.
---
 modules/nativescript/nativescript.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'modules/nativescript/nativescript.cpp')

diff --git a/modules/nativescript/nativescript.cpp b/modules/nativescript/nativescript.cpp
index cb38768f32..0a070988ac 100644
--- a/modules/nativescript/nativescript.cpp
+++ b/modules/nativescript/nativescript.cpp
@@ -792,7 +792,7 @@ NativeScriptInstance::~NativeScriptInstance() {
 		script->instance_owners.erase(owner);
 
 #ifndef NO_THREADS
-		script->owners_lock->lock();
+		script->owners_lock->unlock();
 #endif
 	}
 }
-- 
cgit v1.2.3