diff options
author | Justin Clark-Casey (justincc) | 2012-03-19 21:43:23 +0000 |
---|---|---|
committer | Justin Clark-Casey (justincc) | 2012-03-19 21:45:18 +0000 |
commit | cf91ac68b693e08315a10bc33585900ce4b0b5aa (patch) | |
tree | 852c365aa9a5fd386c6d7340792b2b30c4860265 | |
parent | Clean up "save iar" help (diff) | |
download | opensim-SC_OLD-cf91ac68b693e08315a10bc33585900ce4b0b5aa.zip opensim-SC_OLD-cf91ac68b693e08315a10bc33585900ce4b0b5aa.tar.gz opensim-SC_OLD-cf91ac68b693e08315a10bc33585900ce4b0b5aa.tar.bz2 opensim-SC_OLD-cf91ac68b693e08315a10bc33585900ce4b0b5aa.tar.xz |
Stop console command "xengine status" throwing an exception if there are no scripts in a region.
Addresses http://opensimulator.org/mantis/view.php?id=5940
-rw-r--r-- | OpenSim/Region/ScriptEngine/XEngine/XEngine.cs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/OpenSim/Region/ScriptEngine/XEngine/XEngine.cs b/OpenSim/Region/ScriptEngine/XEngine/XEngine.cs index 0ae6cdf..fa5e3d8 100644 --- a/OpenSim/Region/ScriptEngine/XEngine/XEngine.cs +++ b/OpenSim/Region/ScriptEngine/XEngine/XEngine.cs | |||
@@ -401,16 +401,16 @@ namespace OpenSim.Region.ScriptEngine.XEngine | |||
401 | // sb.AppendFormat("Assemblies loaded : {0}\n", m_Assemblies.Count); | 401 | // sb.AppendFormat("Assemblies loaded : {0}\n", m_Assemblies.Count); |
402 | 402 | ||
403 | SensorRepeat sr = AsyncCommandManager.GetSensorRepeatPlugin(this); | 403 | SensorRepeat sr = AsyncCommandManager.GetSensorRepeatPlugin(this); |
404 | sb.AppendFormat("Sensors : {0}\n", sr.SensorsCount); | 404 | sb.AppendFormat("Sensors : {0}\n", sr != null ? sr.SensorsCount : 0); |
405 | 405 | ||
406 | Dataserver ds = AsyncCommandManager.GetDataserverPlugin(this); | 406 | Dataserver ds = AsyncCommandManager.GetDataserverPlugin(this); |
407 | sb.AppendFormat("Dataserver requests : {0}\n", ds.DataserverRequestsCount); | 407 | sb.AppendFormat("Dataserver requests : {0}\n", ds != null ? ds.DataserverRequestsCount : 0); |
408 | 408 | ||
409 | Timer t = AsyncCommandManager.GetTimerPlugin(this); | 409 | Timer t = AsyncCommandManager.GetTimerPlugin(this); |
410 | sb.AppendFormat("Timers : {0}\n", t.TimersCount); | 410 | sb.AppendFormat("Timers : {0}\n", t != null ? t.TimersCount : 0); |
411 | 411 | ||
412 | Listener l = AsyncCommandManager.GetListenerPlugin(this); | 412 | Listener l = AsyncCommandManager.GetListenerPlugin(this); |
413 | sb.AppendFormat("Listeners : {0}\n", l.ListenerCount); | 413 | sb.AppendFormat("Listeners : {0}\n", l != null ? l.ListenerCount : 0); |
414 | 414 | ||
415 | return sb.ToString(); | 415 | return sb.ToString(); |
416 | } | 416 | } |