aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/ScriptEngine/DotNetEngine/ScriptManager.cs
diff options
context:
space:
mode:
authorTedd Hansen2007-08-26 08:20:48 +0000
committerTedd Hansen2007-08-26 08:20:48 +0000
commit25e200c46a7664eb23499c39e6a1019470e26edc (patch)
tree5b15196e57636dd45f7c530435ba1f665a2c6e20 /OpenSim/Region/ScriptEngine/DotNetEngine/ScriptManager.cs
parentFixed error on shutdown caused by ThreadAbortException sending message throug... (diff)
downloadopensim-SC-25e200c46a7664eb23499c39e6a1019470e26edc.zip
opensim-SC-25e200c46a7664eb23499c39e6a1019470e26edc.tar.gz
opensim-SC-25e200c46a7664eb23499c39e6a1019470e26edc.tar.bz2
opensim-SC-25e200c46a7664eb23499c39e6a1019470e26edc.tar.xz
Fixed bug that occurs sometimes on script unload where queued script event was attempted executed after AppDomain was unloaded.
Diffstat (limited to 'OpenSim/Region/ScriptEngine/DotNetEngine/ScriptManager.cs')
-rw-r--r--OpenSim/Region/ScriptEngine/DotNetEngine/ScriptManager.cs11
1 files changed, 10 insertions, 1 deletions
diff --git a/OpenSim/Region/ScriptEngine/DotNetEngine/ScriptManager.cs b/OpenSim/Region/ScriptEngine/DotNetEngine/ScriptManager.cs
index c7c33bb..5dc928a 100644
--- a/OpenSim/Region/ScriptEngine/DotNetEngine/ScriptManager.cs
+++ b/OpenSim/Region/ScriptEngine/DotNetEngine/ScriptManager.cs
@@ -362,9 +362,18 @@ namespace OpenSim.Region.ScriptEngine.DotNetEngine
362 // Execute a function in the script 362 // Execute a function in the script
363 //m_scriptEngine.Log.Verbose("ScriptEngine", "Executing Function localID: " + localID + ", itemID: " + itemID + ", FunctionName: " + FunctionName); 363 //m_scriptEngine.Log.Verbose("ScriptEngine", "Executing Function localID: " + localID + ", itemID: " + itemID + ", FunctionName: " + FunctionName);
364 LSL_BaseClass Script = m_scriptEngine.myScriptManager.GetScript(localID, itemID); 364 LSL_BaseClass Script = m_scriptEngine.myScriptManager.GetScript(localID, itemID);
365 if (Script == null)
366 return;
365 367
366 // Must be done in correct AppDomain, so leaving it up to the script itself 368 // Must be done in correct AppDomain, so leaving it up to the script itself
367 Script.Exec.ExecuteEvent(FunctionName, args); 369 try
370 {
371 Script.Exec.ExecuteEvent(FunctionName, args);
372 }
373 catch (Exception e)
374 {
375 Console.WriteLine("Exception executing script funcion: " + e.ToString());
376 }
368 377
369 } 378 }
370 379