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 --- .../Handlers/Authorization/AuthorizationServerConnector.cs | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'OpenSim/Server/Handlers/Authorization/AuthorizationServerConnector.cs') diff --git a/OpenSim/Server/Handlers/Authorization/AuthorizationServerConnector.cs b/OpenSim/Server/Handlers/Authorization/AuthorizationServerConnector.cs index 0d9f239..20fd0f7 100644 --- a/OpenSim/Server/Handlers/Authorization/AuthorizationServerConnector.cs +++ b/OpenSim/Server/Handlers/Authorization/AuthorizationServerConnector.cs @@ -37,13 +37,16 @@ namespace OpenSim.Server.Handlers.Authorization public class AuthorizationServerConnector : ServiceConnector { private IAuthorizationService m_AuthorizationService; + private string m_ConfigName = "AuthorizationService"; - public AuthorizationServerConnector(IConfigSource config, IHttpServer server) : - base(config, server) + public AuthorizationServerConnector(IConfigSource config, IHttpServer server, string configName) : + base(config, server, configName) { - IConfig serverConfig = config.Configs["AuthorizationService"]; + if (configName != String.Empty) + m_ConfigName = configName; + IConfig serverConfig = config.Configs[m_ConfigName]; if (serverConfig == null) - throw new Exception("No section 'Server' in config file"); + throw new Exception(String.Format("No section '{0}' in config file", m_ConfigName)); string authorizationService = serverConfig.GetString("LocalServiceModule", String.Empty); -- cgit v1.1