aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/ApplicationPlugins/RemoteController
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/ApplicationPlugins/RemoteController')
-rw-r--r--OpenSim/ApplicationPlugins/RemoteController/RemoteAdminPlugin.cs35
1 files changed, 19 insertions, 16 deletions
diff --git a/OpenSim/ApplicationPlugins/RemoteController/RemoteAdminPlugin.cs b/OpenSim/ApplicationPlugins/RemoteController/RemoteAdminPlugin.cs
index c37fcba..b9559c0 100644
--- a/OpenSim/ApplicationPlugins/RemoteController/RemoteAdminPlugin.cs
+++ b/OpenSim/ApplicationPlugins/RemoteController/RemoteAdminPlugin.cs
@@ -28,22 +28,25 @@ namespace OpenSim.ApplicationPlugins.LoadRegions
28 28
29 public void Initialise(OpenSimMain openSim) 29 public void Initialise(OpenSimMain openSim)
30 { 30 {
31 IConfig remoteConfig = openSim.ConfigSource.Configs["RemoteAdmin"]; 31 try
32 if (remoteConfig != null) 32 {
33 { 33 if (openSim.ConfigSource.Configs["RemoteAdmin"].GetBoolean("enabled", false))
34 if (remoteConfig.GetBoolean("enabled", false)) 34 {
35 { 35 OpenSim.Framework.Console.MainLog.Instance.Verbose("RADMIN", "Remote Admin Plugin Enabled");
36 System.Console.WriteLine("RADMIN", "Remote Admin Plugin Enabled"); 36
37 37 m_app = openSim;
38 m_app = openSim; 38 m_httpd = openSim.HttpServer;
39 m_httpd = openSim.HttpServer; 39
40 40 m_httpd.AddXmlRPCHandler("admin_create_region", XmlRpcCreateRegionMethod);
41 m_httpd.AddXmlRPCHandler("admin_create_region", XmlRpcCreateRegionMethod); 41 m_httpd.AddXmlRPCHandler("admin_shutdown", XmlRpcShutdownMethod);
42 m_httpd.AddXmlRPCHandler("admin_shutdown", XmlRpcShutdownMethod); 42 m_httpd.AddXmlRPCHandler("admin_broadcast", XmlRpcAlertMethod);
43 m_httpd.AddXmlRPCHandler("admin_broadcast", XmlRpcAlertMethod); 43 m_httpd.AddXmlRPCHandler("admin_restart", XmlRpcRestartMethod);
44 m_httpd.AddXmlRPCHandler("admin_restart", XmlRpcRestartMethod); 44 }
45 } 45 }
46 } 46 catch (NullReferenceException)
47 {
48 // Ignore.
49 }
47 } 50 }
48 51
49 public XmlRpcResponse XmlRpcRestartMethod(XmlRpcRequest request) 52 public XmlRpcResponse XmlRpcRestartMethod(XmlRpcRequest request)