From fa45d5b5faf222a8a8e976e2827dad5b65d42583 Mon Sep 17 00:00:00 2001 From: Melanie Date: Mon, 19 Jul 2010 01:10:57 +0100 Subject: Revert "A stab in the dark. Revert the compile lockout temporarily. If you know what" This reverts commit f798679b8005e532f933553007cca989112f4a1d. --- OpenSim/Region/ScriptEngine/XEngine/XEngine.cs | 40 +++++++++++++------------- 1 file changed, 20 insertions(+), 20 deletions(-) diff --git a/OpenSim/Region/ScriptEngine/XEngine/XEngine.cs b/OpenSim/Region/ScriptEngine/XEngine/XEngine.cs index bf7fed8..0299385 100644 --- a/OpenSim/Region/ScriptEngine/XEngine/XEngine.cs +++ b/OpenSim/Region/ScriptEngine/XEngine/XEngine.cs @@ -122,7 +122,7 @@ namespace OpenSim.Region.ScriptEngine.XEngine private ScriptCompileQueue m_CompileQueue = new ScriptCompileQueue(); IWorkItemResult m_CurrentCompile = null; -// private Dictionary m_CompileDict = new Dictionary(); + private Dictionary m_CompileDict = new Dictionary(); public string ScriptEngineName { @@ -488,20 +488,20 @@ namespace OpenSim.Region.ScriptEngine.XEngine if (stateSource == (int)StateSource.ScriptedRez) { -// lock (m_CompileDict) -// { -// m_CompileDict[itemID] = 0; -// } + lock (m_CompileDict) + { + m_CompileDict[itemID] = 0; + } DoOnRezScript(parms); } else { m_CompileQueue.Enqueue(parms); -// lock (m_CompileDict) -// { -// m_CompileDict[itemID] = 0; -// } + lock (m_CompileDict) + { + m_CompileDict[itemID] = 0; + } if (m_CurrentCompile == null) { @@ -564,12 +564,12 @@ namespace OpenSim.Region.ScriptEngine.XEngine bool postOnRez = (bool)p[4]; StateSource stateSource = (StateSource)p[5]; -// lock(m_CompileDict) -// { -// if (!m_CompileDict.ContainsKey(itemID)) -// return false; -// m_CompileDict.Remove(itemID); -// } + lock(m_CompileDict) + { + if (!m_CompileDict.ContainsKey(itemID)) + return false; + m_CompileDict.Remove(itemID); + } // Get the asset ID of the script, so we can check if we // already have it. @@ -814,11 +814,11 @@ namespace OpenSim.Region.ScriptEngine.XEngine public void OnRemoveScript(uint localID, UUID itemID) { // If it's not yet been compiled, make sure we don't try -// lock (m_CompileDict) -// { -// if (m_CompileDict.ContainsKey(itemID)) -// m_CompileDict.Remove(itemID); -// } + lock (m_CompileDict) + { + if (m_CompileDict.ContainsKey(itemID)) + m_CompileDict.Remove(itemID); + } lock (m_Scripts) { -- cgit v1.1