From 691f1e8aa08db84b689793ea9cd2c72bcfdd9b17 Mon Sep 17 00:00:00 2001 From: Melanie Date: Tue, 29 Sep 2009 09:56:17 +0100 Subject: Fix loading modules with alternate configurations and ports into ROBUST. Make all current modules support the configuration name option --- OpenSim/Server/ServerMain.cs | 34 ++++++++++++++-------------------- 1 file changed, 14 insertions(+), 20 deletions(-) (limited to 'OpenSim/Server/ServerMain.cs') diff --git a/OpenSim/Server/ServerMain.cs b/OpenSim/Server/ServerMain.cs index 01f2649..a7b33c9 100644 --- a/OpenSim/Server/ServerMain.cs +++ b/OpenSim/Server/ServerMain.cs @@ -96,29 +96,23 @@ namespace OpenSim.Server if (port != 0) server = m_Server.GetHttpServer(port); - m_log.InfoFormat("[SERVER]: Loading {0}", friendlyName); + if (port != m_Server.DefaultPort) + m_log.InfoFormat("[SERVER]: Loading {0} on port {1}", friendlyName, port); + else + m_log.InfoFormat("[SERVER]: Loading {0}", friendlyName); IServiceConnector connector = null; - try - { - Object[] modargs = null; - if (configName != string.Empty) - { - modargs = new Object[] { m_Server.Config, server, - configName }; - connector = ServerUtils.LoadPlugin(conn, - modargs); - } - if (connector == null) - { - modargs = new Object[] { m_Server.Config, server }; - connector = - ServerUtils.LoadPlugin(conn, - modargs); - } - } - catch (Exception) + + Object[] modargs = new Object[] { m_Server.Config, server, + configName }; + connector = ServerUtils.LoadPlugin(conn, + modargs); + if (connector == null) { + modargs = new Object[] { m_Server.Config, server }; + connector = + ServerUtils.LoadPlugin(conn, + modargs); } if (connector != null) -- cgit v1.1