aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/MaintenanceThread.cs10
-rw-r--r--OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/ScriptEngine.cs4
-rw-r--r--OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/ScriptManager.cs4
3 files changed, 12 insertions, 6 deletions
diff --git a/OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/MaintenanceThread.cs b/OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/MaintenanceThread.cs
index 1a5cca1..14f7c4f 100644
--- a/OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/MaintenanceThread.cs
+++ b/OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/MaintenanceThread.cs
@@ -58,7 +58,12 @@ namespace OpenSim.Region.ScriptEngine.Common.ScriptEngineBase
58 58
59 public void ReadConfig() 59 public void ReadConfig()
60 { 60 {
61 MaintenanceLoopms = m_ScriptEngine.ScriptConfigSource.GetInt("MaintenanceLoopms", 50); 61 // Bad hack, but we need a m_ScriptEngine :)
62 foreach (ScriptEngine m_ScriptEngine in ScriptEngine.ScriptEngines)
63 {
64 MaintenanceLoopms = m_ScriptEngine.ScriptConfigSource.GetInt("MaintenanceLoopms", 50);
65 return;
66 }
62 } 67 }
63 68
64 #region " Maintenance thread " 69 #region " Maintenance thread "
@@ -169,7 +174,8 @@ namespace OpenSim.Region.ScriptEngine.Common.ScriptEngineBase
169 } 174 }
170 catch (Exception ex) 175 catch (Exception ex)
171 { 176 {
172 ScriptEngine.Log.Error("[" + lastScriptEngine.ScriptEngineName + "]: Exception in MaintenanceLoopThread. Thread will recover after 5 sec throttle. Exception: " + ex.ToString()); 177 if (lastScriptEngine != null)
178 lastScriptEngine.Log.Error("[" + lastScriptEngine.ScriptEngineName + "]: Exception in MaintenanceLoopThread. Thread will recover after 5 sec throttle. Exception: " + ex.ToString());
173 Thread.Sleep(5000); 179 Thread.Sleep(5000);
174 } 180 }
175 } 181 }
diff --git a/OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/ScriptEngine.cs b/OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/ScriptEngine.cs
index 67eefd9..0d087ed 100644
--- a/OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/ScriptEngine.cs
+++ b/OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/ScriptEngine.cs
@@ -45,7 +45,7 @@ namespace OpenSim.Region.ScriptEngine.Common.ScriptEngineBase
45 [Serializable] 45 [Serializable]
46 public abstract class ScriptEngine : IRegionModule, OpenSim.Region.ScriptEngine.Common.ScriptServerInterfaces.ScriptEngine, iScriptEngineFunctionModule 46 public abstract class ScriptEngine : IRegionModule, OpenSim.Region.ScriptEngine.Common.ScriptServerInterfaces.ScriptEngine, iScriptEngineFunctionModule
47 { 47 {
48 private static readonly log4net.ILog m_log = log4net.LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType); 48 private readonly log4net.ILog m_log = log4net.LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType);
49 49
50 public static List<ScriptEngine> ScriptEngines = new List<ScriptEngine>(); 50 public static List<ScriptEngine> ScriptEngines = new List<ScriptEngine>();
51 public Scene World; 51 public Scene World;
@@ -76,7 +76,7 @@ namespace OpenSim.Region.ScriptEngine.Common.ScriptEngineBase
76 76
77 public abstract ScriptManager _GetScriptManager(); 77 public abstract ScriptManager _GetScriptManager();
78 78
79 public static log4net.ILog Log 79 public log4net.ILog Log
80 { 80 {
81 get { return m_log; } 81 get { return m_log; }
82 } 82 }
diff --git a/OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/ScriptManager.cs b/OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/ScriptManager.cs
index b50c184..20ff07a 100644
--- a/OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/ScriptManager.cs
+++ b/OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/ScriptManager.cs
@@ -194,8 +194,8 @@ namespace OpenSim.Region.ScriptEngine.Common.ScriptEngineBase
194 { 194 {
195 if (LUQueue.Count == 0) 195 if (LUQueue.Count == 0)
196 Thread.Sleep(scriptLoadUnloadThread_IdleSleepms); 196 Thread.Sleep(scriptLoadUnloadThread_IdleSleepms);
197 if (PleaseShutdown) 197 //if (PleaseShutdown)
198 return; 198 // return;
199 if (LUQueue.Count > 0) 199 if (LUQueue.Count > 0)
200 { 200 {
201 LUStruct item = LUQueue.Dequeue(); 201 LUStruct item = LUQueue.Dequeue();