Don't execute rest of code in XEngine.RemoveRegion() and Close() if the module is disabled.

remove-scene-viewer
Justin Clark-Casey (justincc) 2011-10-14 01:06:43 +01:00
parent 4e7d4330c2
commit ee84c0589c
1 changed files with 6 additions and 0 deletions

View File

@ -269,6 +269,9 @@ namespace OpenSim.Region.ScriptEngine.XEngine
public void RemoveRegion(Scene scene)
{
if (!m_Enabled)
return;
lock (m_Scripts)
{
m_log.InfoFormat(
@ -351,6 +354,9 @@ namespace OpenSim.Region.ScriptEngine.XEngine
public void Close()
{
if (!m_Enabled)
return;
lock (m_ScriptEngines)
{
if (m_ScriptEngines.Contains(this))