From b16abc8166c29585cb76cc55c3bdd76e5833cb4f Mon Sep 17 00:00:00 2001 From: Melanie Thielker Date: Thu, 5 Jan 2017 19:07:37 +0000 Subject: Massive tab and trailing space cleanup --- OpenSim/Server/Base/CommandManager.cs | 90 ++++++++--------- OpenSim/Server/Base/HttpServerBase.cs | 2 +- OpenSim/Server/Base/Properties/AssemblyInfo.cs | 8 +- OpenSim/Server/Base/ProtocolVersions.cs | 14 +-- OpenSim/Server/Base/ServerUtils.cs | 42 ++++---- OpenSim/Server/Base/ServicesServerBase.cs | 4 +- .../Server/Handlers/Asset/AssetServerConnector.cs | 14 +-- .../Server/Handlers/Asset/AssetServerGetHandler.cs | 4 +- .../Asset/Tests/AssetServerPostHandlerTests.cs | 12 +-- .../AuthenticationServerPostHandler.cs | 20 ++-- .../Authentication/OpenIdServerConnector.cs | 2 +- .../Handlers/Authentication/OpenIdServerHandler.cs | 6 +- .../AuthorizationServerPostHandler.cs | 2 +- .../Handlers/Avatar/AvatarServerPostHandler.cs | 6 +- .../Server/Handlers/BakedTextures/XBakesHandler.cs | 2 +- OpenSim/Server/Handlers/Base/ServerConnector.cs | 6 +- OpenSim/Server/Handlers/Grid/GridInfoHandlers.cs | 10 +- .../Server/Handlers/Grid/GridServerPostHandler.cs | 10 +- OpenSim/Server/Handlers/Hypergrid/AgentHandlers.cs | 2 +- .../Handlers/Hypergrid/HGFriendServerConnector.cs | 2 +- .../Hypergrid/HGFriendsServerPostHandler.cs | 12 +-- .../Hypergrid/InstantMessageServerConnector.cs | 2 +- .../Handlers/Hypergrid/UserAgentServerConnector.cs | 4 +- .../Inventory/InventoryServerInConnector.cs | 6 +- .../Handlers/Inventory/XInventoryInConnector.cs | 4 +- .../Server/Handlers/Land/LandServiceInConnector.cs | 2 +- OpenSim/Server/Handlers/Login/LLLoginHandlers.cs | 8 +- .../Handlers/Login/LLLoginServiceInConnector.cs | 4 +- .../Server/Handlers/Map/MapAddServerConnector.cs | 2 +- .../Handlers/Map/MapRemoveServerConnector.cs | 2 +- .../Server/Handlers/Neighbour/NeighbourHandlers.cs | 2 +- .../Neighbour/NeighbourServiceInConnector.cs | 2 +- .../Handlers/Presence/PresenceServerPostHandler.cs | 4 +- .../Handlers/Profiles/UserProfilesConnector.cs | 6 +- .../Handlers/Profiles/UserProfilesHandlers.cs | 108 ++++++++++----------- OpenSim/Server/Handlers/Properties/AssemblyInfo.cs | 8 +- .../Server/Handlers/Simulation/AgentHandlers.cs | 10 +- OpenSim/Server/Properties/AssemblyInfo.cs | 8 +- OpenSim/Server/ServerMain.cs | 4 +- 39 files changed, 228 insertions(+), 228 deletions(-) (limited to 'OpenSim/Server') diff --git a/OpenSim/Server/Base/CommandManager.cs b/OpenSim/Server/Base/CommandManager.cs index bd18485..b6e2903 100644 --- a/OpenSim/Server/Base/CommandManager.cs +++ b/OpenSim/Server/Base/CommandManager.cs @@ -41,117 +41,117 @@ namespace OpenSim.Server.Base { /// /// Command manager - - /// Wrapper for OpenSim.Framework.PluginManager to allow + /// Wrapper for OpenSim.Framework.PluginManager to allow /// us to add commands to the console to perform operations /// on our repos and plugins /// - public class CommandManager - { - public AddinRegistry PluginRegistry; - protected PluginManager PluginManager; + public class CommandManager + { + public AddinRegistry PluginRegistry; + protected PluginManager PluginManager; - public CommandManager(AddinRegistry registry) + public CommandManager(AddinRegistry registry) { - PluginRegistry = registry; - PluginManager = new PluginManager(PluginRegistry); - AddManagementCommands(); - } - - private void AddManagementCommands() - { - // add plugin - MainConsole.Instance.Commands.AddCommand("Plugin", true, + PluginRegistry = registry; + PluginManager = new PluginManager(PluginRegistry); + AddManagementCommands(); + } + + private void AddManagementCommands() + { + // add plugin + MainConsole.Instance.Commands.AddCommand("Plugin", true, "plugin add", "plugin add \"plugin index\"", - "Install plugin from repository.", + "Install plugin from repository.", HandleConsoleInstallPlugin); - // remove plugin + // remove plugin MainConsole.Instance.Commands.AddCommand("Plugin", true, "plugin remove", "plugin remove \"plugin index\"", - "Remove plugin from repository", + "Remove plugin from repository", HandleConsoleUnInstallPlugin); - // list installed plugins + // list installed plugins MainConsole.Instance.Commands.AddCommand("Plugin", true, - "plugin list installed", - "plugin list installed","List install plugins", + "plugin list installed", + "plugin list installed","List install plugins", HandleConsoleListInstalledPlugin); - // list plugins available from registered repositories + // list plugins available from registered repositories MainConsole.Instance.Commands.AddCommand("Plugin", true, "plugin list available", - "plugin list available","List available plugins", + "plugin list available","List available plugins", HandleConsoleListAvailablePlugin); - // List available updates + // List available updates MainConsole.Instance.Commands.AddCommand("Plugin", true, "plugin updates", "plugin updates","List availble updates", HandleConsoleListUpdates); - // Update plugin + // Update plugin MainConsole.Instance.Commands.AddCommand("Plugin", true, "plugin update", "plugin update \"plugin index\"","Update the plugin", HandleConsoleUpdatePlugin); - // Add repository + // Add repository MainConsole.Instance.Commands.AddCommand("Repository", true, "repo add", "repo add \"url\"","Add repository", HandleConsoleAddRepo); - // Refresh repo + // Refresh repo MainConsole.Instance.Commands.AddCommand("Repository", true, "repo refresh", "repo refresh \"url\"", "Sync with a registered repository", HandleConsoleGetRepo); - // Remove repository from registry + // Remove repository from registry MainConsole.Instance.Commands.AddCommand("Repository", true, "repo remove", - "repo remove \"[url | index]\"", - "Remove repository from registry", + "repo remove \"[url | index]\"", + "Remove repository from registry", HandleConsoleRemoveRepo); - // Enable repo + // Enable repo MainConsole.Instance.Commands.AddCommand("Repository", true, "repo enable", "repo enable \"[url | index]\"", - "Enable registered repository", + "Enable registered repository", HandleConsoleEnableRepo); - // Disable repo + // Disable repo MainConsole.Instance.Commands.AddCommand("Repository", true, "repo disable", "repo disable\"[url | index]\"", - "Disable registered repository", + "Disable registered repository", HandleConsoleDisableRepo); - // List registered repositories + // List registered repositories MainConsole.Instance.Commands.AddCommand("Repository", true, "repo list", "repo list", - "List registered repositories", + "List registered repositories", HandleConsoleListRepos); - // * + // * MainConsole.Instance.Commands.AddCommand("Plugin", true, "plugin info", "plugin info \"plugin index\"","Show detailed information for plugin", HandleConsoleShowAddinInfo); - // Plugin disable + // Plugin disable MainConsole.Instance.Commands.AddCommand("Plugin", true, "plugin disable", "plugin disable \"plugin index\"", - "Disable a plugin", + "Disable a plugin", HandleConsoleDisablePlugin); - // Enable plugin + // Enable plugin MainConsole.Instance.Commands.AddCommand("Plugin", true, "plugin enable", "plugin enable \"plugin index\"", - "Enable the selected plugin plugin", + "Enable the selected plugin plugin", HandleConsoleEnablePlugin); } - + #region console handlers // Handle our console commands // // Install plugin from registered repository /// /// Handles the console install plugin command. Attempts to install the selected plugin - /// and + /// and /// /// /// Module. @@ -323,7 +323,7 @@ namespace OpenSim.Server.Base { if (cmd.Length >= 3) { - + Dictionary result = new Dictionary(); int ndx = Convert.ToInt16(cmd[2]); @@ -355,5 +355,5 @@ namespace OpenSim.Server.Base return; } #endregion - } + } } \ No newline at end of file diff --git a/OpenSim/Server/Base/HttpServerBase.cs b/OpenSim/Server/Base/HttpServerBase.cs index 42a8c57..3357250 100644 --- a/OpenSim/Server/Base/HttpServerBase.cs +++ b/OpenSim/Server/Base/HttpServerBase.cs @@ -112,7 +112,7 @@ namespace OpenSim.Server.Base MainServer.Instance = httpServer; // If https_listener = true, then add an ssl listener on the https_port... - if (ssl_listener == true) + if (ssl_listener == true) { uint https_port = (uint)networkConfig.GetInt("https_port", 0); diff --git a/OpenSim/Server/Base/Properties/AssemblyInfo.cs b/OpenSim/Server/Base/Properties/AssemblyInfo.cs index 02931e7..4be0f25 100644 --- a/OpenSim/Server/Base/Properties/AssemblyInfo.cs +++ b/OpenSim/Server/Base/Properties/AssemblyInfo.cs @@ -2,7 +2,7 @@ using System.Runtime.CompilerServices; using System.Runtime.InteropServices; -// General Information about an assembly is controlled through the following +// General Information about an assembly is controlled through the following // set of attributes. Change these attribute values to modify the information // associated with an assembly. [assembly: AssemblyTitle("OpenSim.Server.Base")] @@ -14,8 +14,8 @@ using System.Runtime.InteropServices; [assembly: AssemblyTrademark("")] [assembly: AssemblyCulture("")] -// Setting ComVisible to false makes the types in this assembly not visible -// to COM components. If you need to access a type in this assembly from +// Setting ComVisible to false makes the types in this assembly not visible +// to COM components. If you need to access a type in this assembly from // COM, set the ComVisible attribute to true on that type. [assembly: ComVisible(false)] @@ -25,7 +25,7 @@ using System.Runtime.InteropServices; // Version information for an assembly consists of the following four values: // // Major Version -// Minor Version +// Minor Version // Build Number // Revision // diff --git a/OpenSim/Server/Base/ProtocolVersions.cs b/OpenSim/Server/Base/ProtocolVersions.cs index 5c2278c..27eed4c 100644 --- a/OpenSim/Server/Base/ProtocolVersions.cs +++ b/OpenSim/Server/Base/ProtocolVersions.cs @@ -31,20 +31,20 @@ namespace OpenSim.Server.Base { /// /// This is the external protocol versions. It is separate from the OpenSimulator project version. - /// + /// /// These version numbers should be increased by 1 every time a code - /// change in the Service.Connectors and Server.Handlers, espectively, + /// change in the Service.Connectors and Server.Handlers, espectively, /// makes the previous OpenSimulator revision incompatible - /// with the new revision. - /// + /// with the new revision. + /// /// Changes which are compatible with an older revision (e.g. older revisions experience degraded functionality /// but not outright failure) do not need a version number increment. - /// + /// /// Having this version number allows the grid service to reject connections from regions running a version - /// of the code that is too old. + /// of the code that is too old. /// /// - + // The range of acceptable servers for client-side connectors public readonly static int ClientProtocolVersionMin = 1; public readonly static int ClientProtocolVersionMax = 1; diff --git a/OpenSim/Server/Base/ServerUtils.cs b/OpenSim/Server/Base/ServerUtils.cs index 57d0a8d..b17d7ba 100644 --- a/OpenSim/Server/Base/ServerUtils.cs +++ b/OpenSim/Server/Base/ServerUtils.cs @@ -104,7 +104,7 @@ namespace OpenSim.Server.Base // libomv, which has a hard-coded path to "." for pinvoke // to load the openjpeg dll // - // Will look for a way to fix, but for now this keeps the + // Will look for a way to fix, but for now this keeps the // confusion to a minimum. this was copied from our region // plugin loader, we have been doing this in there for a long time. // @@ -183,7 +183,7 @@ namespace OpenSim.Server.Base if(port != 0) server = MainServer.GetHttpServer(port); - else + else server = MainServer.Instance; return server; @@ -222,19 +222,19 @@ namespace OpenSim.Server.Base // This is good to debug configuration problems //if (dllName == string.Empty) // Util.PrintCallStack(); - + string className = String.Empty; // The path for a dynamic plugin will contain ":" on Windows string[] parts = dllName.Split (new char[] {':'}); - if (parts [0].Length > 1) + if (parts [0].Length > 1) { dllName = parts [0]; if (parts.Length > 1) className = parts[1]; - } - else + } + else { // This is Windows - we must replace the ":" in the path dllName = String.Format ("{0}:{1}", parts [0], parts [1]); @@ -242,17 +242,17 @@ namespace OpenSim.Server.Base className = parts[2]; } - // Handle extra string arguments in a more generic way - if (dllName.Contains("@")) - { - string[] dllNameParts = dllName.Split(new char[] {'@'}); - dllName = dllNameParts[dllNameParts.Length - 1]; - List argList = new List(args); - for (int i = 0 ; i < dllNameParts.Length - 1 ; ++i) - argList.Add(dllNameParts[i]); + // Handle extra string arguments in a more generic way + if (dllName.Contains("@")) + { + string[] dllNameParts = dllName.Split(new char[] {'@'}); + dllName = dllNameParts[dllNameParts.Length - 1]; + List argList = new List(args); + for (int i = 0 ; i < dllNameParts.Length - 1 ; ++i) + argList.Add(dllNameParts[i]); - args = argList.ToArray(); - } + args = argList.ToArray(); + } return LoadPlugin(dllName, className, args); } @@ -276,10 +276,10 @@ namespace OpenSim.Server.Base { if (pluginType.IsPublic) { - if (className != String.Empty + if (className != String.Empty && pluginType.ToString() != pluginType.Namespace + "." + className) continue; - + Type typeInterface = pluginType.GetInterface(interfaceName); if (typeInterface != null) @@ -295,8 +295,8 @@ namespace OpenSim.Server.Base if (!(e is System.MissingMethodException)) { m_log.Error(string.Format("[SERVER UTILS]: Error loading plugin {0} from {1}. Exception: {2}", - interfaceName, - dllName, + interfaceName, + dllName, e.InnerException == null ? e.Message : e.InnerException.Message), e); } @@ -479,7 +479,7 @@ namespace OpenSim.Server.Base XmlDocument doc = new XmlDocument(); doc.LoadXml(data); - + XmlNodeList rootL = doc.GetElementsByTagName("ServerResponse"); if (rootL.Count != 1) diff --git a/OpenSim/Server/Base/ServicesServerBase.cs b/OpenSim/Server/Base/ServicesServerBase.cs index e18594f..f60b5fb 100644 --- a/OpenSim/Server/Base/ServicesServerBase.cs +++ b/OpenSim/Server/Base/ServicesServerBase.cs @@ -92,7 +92,7 @@ namespace OpenSim.Server.Base // Check if a prompt was given on the command line prompt = startupConfig.GetString("prompt", prompt); - + // Check for a Log4Net config file on the command line logConfig =startupConfig.GetString("logconfig", logConfig); } @@ -116,7 +116,7 @@ namespace OpenSim.Server.Base // Merge OpSys env vars Console.WriteLine("[CONFIG]: Loading environment variables for Config"); Util.MergeEnvironmentToConfig(Config); - + // Merge the configuration from the command line into the loaded file Config.Merge(argvConfig); diff --git a/OpenSim/Server/Handlers/Asset/AssetServerConnector.cs b/OpenSim/Server/Handlers/Asset/AssetServerConnector.cs index ab81dd6..bad3ea2 100644 --- a/OpenSim/Server/Handlers/Asset/AssetServerConnector.cs +++ b/OpenSim/Server/Handlers/Asset/AssetServerConnector.cs @@ -151,27 +151,27 @@ namespace OpenSim.Server.Handlers.Asset MainConsole.Instance.OutputFormat("ERROR: {0} is not a valid ID format", rawAssetId); return; } - + AssetBase asset = m_AssetService.Get(assetId.ToString()); if (asset == null) - { + { MainConsole.Instance.OutputFormat("ERROR: No asset found with ID {0}", assetId); - return; + return; } - + string fileName = rawAssetId; if (!ConsoleUtil.CheckFileDoesNotExist(MainConsole.Instance, fileName)) return; - + using (FileStream fs = new FileStream(fileName, FileMode.CreateNew)) { using (BinaryWriter bw = new BinaryWriter(fs)) { bw.Write(asset.Data); } - } - + } + MainConsole.Instance.OutputFormat("Asset dumped to file {0}", fileName); } diff --git a/OpenSim/Server/Handlers/Asset/AssetServerGetHandler.cs b/OpenSim/Server/Handlers/Asset/AssetServerGetHandler.cs index 91c5c54..8bfc690 100644 --- a/OpenSim/Server/Handlers/Asset/AssetServerGetHandler.cs +++ b/OpenSim/Server/Handlers/Asset/AssetServerGetHandler.cs @@ -53,7 +53,7 @@ namespace OpenSim.Server.Handlers.Asset public AssetServerGetHandler(IAssetService service) : base("GET", "/assets") { - m_AssetService = service; + m_AssetService = service; } public AssetServerGetHandler(IAssetService service, IServiceAuth auth, string redirectURL) : @@ -155,7 +155,7 @@ namespace OpenSim.Server.Handlers.Asset httpResponse.ContentType = "text/plain"; result = new byte[0]; } - + if (httpResponse.StatusCode == (int)HttpStatusCode.NotFound && !string.IsNullOrEmpty(m_RedirectURL) && !string.IsNullOrEmpty(id)) { httpResponse.StatusCode = (int)HttpStatusCode.Redirect; diff --git a/OpenSim/Server/Handlers/Asset/Tests/AssetServerPostHandlerTests.cs b/OpenSim/Server/Handlers/Asset/Tests/AssetServerPostHandlerTests.cs index faa6fb7..4d2228a 100644 --- a/OpenSim/Server/Handlers/Asset/Tests/AssetServerPostHandlerTests.cs +++ b/OpenSim/Server/Handlers/Asset/Tests/AssetServerPostHandlerTests.cs @@ -52,8 +52,8 @@ namespace OpenSim.Server.Handlers.Asset.Test UUID assetId = TestHelpers.ParseTail(0x1); - IConfigSource config = new IniConfigSource(); - config.AddConfig("AssetService"); + IConfigSource config = new IniConfigSource(); + config.AddConfig("AssetService"); config.Configs["AssetService"].Set("StorageProvider", "OpenSim.Tests.Common.dll"); AssetService assetService = new AssetService(config); @@ -72,7 +72,7 @@ namespace OpenSim.Server.Handlers.Asset.Test XmlSerializer serializer = new XmlSerializer(typeof(AssetBase)); serializer.Serialize(writer, asset); writer.Flush(); - } + } buffer.Position = 0; asph.Handle(null, buffer, null, null); @@ -87,13 +87,13 @@ namespace OpenSim.Server.Handlers.Asset.Test { TestHelpers.InMethod(); - IConfigSource config = new IniConfigSource(); - config.AddConfig("AssetService"); + IConfigSource config = new IniConfigSource(); + config.AddConfig("AssetService"); config.Configs["AssetService"].Set("StorageProvider", "OpenSim.Tests.Common.dll"); AssetService assetService = new AssetService(config); - AssetServerPostHandler asph = new AssetServerPostHandler(assetService); + AssetServerPostHandler asph = new AssetServerPostHandler(assetService); MemoryStream buffer = new MemoryStream(); byte[] badData = new byte[] { 0x48, 0x65, 0x6c, 0x6c, 0x6f }; diff --git a/OpenSim/Server/Handlers/Authentication/AuthenticationServerPostHandler.cs b/OpenSim/Server/Handlers/Authentication/AuthenticationServerPostHandler.cs index 6ee98b3..d3ea7e2 100644 --- a/OpenSim/Server/Handlers/Authentication/AuthenticationServerPostHandler.cs +++ b/OpenSim/Server/Handlers/Authentication/AuthenticationServerPostHandler.cs @@ -132,41 +132,41 @@ namespace OpenSim.Server.Handlers.Authentication case "authenticate": if (!request.ContainsKey("PASSWORD")) return FailureResult(); - + token = m_AuthenticationService.Authenticate(principalID, request["PASSWORD"].ToString(), lifetime); - + if (token != String.Empty) return SuccessResult(token); return FailureResult(); - + case "setpassword": if (!m_AllowSetPassword) return FailureResult(); if (!request.ContainsKey("PASSWORD")) return FailureResult(); - + if (m_AuthenticationService.SetPassword(principalID, request["PASSWORD"].ToString())) return SuccessResult(); else return FailureResult(); - + case "verify": if (!request.ContainsKey("TOKEN")) return FailureResult(); - + if (m_AuthenticationService.Verify(principalID, request["TOKEN"].ToString(), lifetime)) return SuccessResult(); - + return FailureResult(); - + case "release": if (!request.ContainsKey("TOKEN")) return FailureResult(); - + if (m_AuthenticationService.Release(principalID, request["TOKEN"].ToString())) return SuccessResult(); - + return FailureResult(); case "getauthinfo": diff --git a/OpenSim/Server/Handlers/Authentication/OpenIdServerConnector.cs b/OpenSim/Server/Handlers/Authentication/OpenIdServerConnector.cs index 6464399..ac8ff52 100644 --- a/OpenSim/Server/Handlers/Authentication/OpenIdServerConnector.cs +++ b/OpenSim/Server/Handlers/Authentication/OpenIdServerConnector.cs @@ -41,7 +41,7 @@ namespace OpenSim.Server.Handlers.Authentication private static readonly ILog m_log = LogManager.GetLogger( MethodBase.GetCurrentMethod().DeclaringType); - + private IAuthenticationService m_AuthenticationService; private IUserAccountService m_UserAccountService; private string m_ConfigName = "OpenIdService"; diff --git a/OpenSim/Server/Handlers/Authentication/OpenIdServerHandler.cs b/OpenSim/Server/Handlers/Authentication/OpenIdServerHandler.cs index b201dc7..a6605a1 100644 --- a/OpenSim/Server/Handlers/Authentication/OpenIdServerHandler.cs +++ b/OpenSim/Server/Handlers/Authentication/OpenIdServerHandler.cs @@ -178,14 +178,14 @@ namespace OpenSim.Server.Handlers.Authentication "; /// Page shown for an invalid OpenID identity - const string INVALID_OPENID_PAGE = + const string INVALID_OPENID_PAGE = @"Identity not found Invalid OpenID identity"; /// Page shown if the OpenID endpoint is requested directly const string ENDPOINT_PAGE = @"OpenID Endpoint -This is an OpenID server endpoint, not a human-readable resource. +This is an OpenID server endpoint, not a human-readable resource. For more information, see http://openid.net/. "; @@ -241,7 +241,7 @@ For more information, see http://openid.net/. // Check for form POST data if (passwordValues != null && passwordValues.Length == 1) { - if (account != null && + if (account != null && (m_authenticationService.Authenticate(account.PrincipalID,Util.Md5Hash(passwordValues[0]), 30) != string.Empty)) authRequest.IsAuthenticated = true; else diff --git a/OpenSim/Server/Handlers/Authorization/AuthorizationServerPostHandler.cs b/OpenSim/Server/Handlers/Authorization/AuthorizationServerPostHandler.cs index c9b4e9b..310a542 100644 --- a/OpenSim/Server/Handlers/Authorization/AuthorizationServerPostHandler.cs +++ b/OpenSim/Server/Handlers/Authorization/AuthorizationServerPostHandler.cs @@ -67,7 +67,7 @@ namespace OpenSim.Server.Handlers.Authorization xs = new XmlSerializer(typeof(AuthorizationResponse)); return ServerUtils.SerializeResult(xs, result); - + } } } diff --git a/OpenSim/Server/Handlers/Avatar/AvatarServerPostHandler.cs b/OpenSim/Server/Handlers/Avatar/AvatarServerPostHandler.cs index ff8699f..69c1a89 100644 --- a/OpenSim/Server/Handlers/Avatar/AvatarServerPostHandler.cs +++ b/OpenSim/Server/Handlers/Avatar/AvatarServerPostHandler.cs @@ -175,7 +175,7 @@ namespace OpenSim.Server.Handlers.Avatar request.Remove("METHOD"); request.Remove("UserID"); } - + byte[] SetItems(Dictionary request) { UUID user = UUID.Zero; @@ -196,7 +196,7 @@ namespace OpenSim.Server.Handlers.Avatar names = _names.ToArray(); List _values = (List)request["Values"]; values = _values.ToArray(); - + if (m_AvatarService.SetItems(user, names, values)) return SuccessResult(); @@ -227,7 +227,7 @@ namespace OpenSim.Server.Handlers.Avatar } - + private byte[] SuccessResult() { XmlDocument doc = new XmlDocument(); diff --git a/OpenSim/Server/Handlers/BakedTextures/XBakesHandler.cs b/OpenSim/Server/Handlers/BakedTextures/XBakesHandler.cs index 4c12967..4386a2d 100644 --- a/OpenSim/Server/Handlers/BakedTextures/XBakesHandler.cs +++ b/OpenSim/Server/Handlers/BakedTextures/XBakesHandler.cs @@ -61,7 +61,7 @@ namespace OpenSim.Server.Handlers.BakedTextures ServerUtils.LoadPlugin(assetService, args); IServiceAuth auth = ServiceAuth.Create(config, m_ConfigName); - + server.AddStreamHandler(new BakesServerGetHandler(m_BakesService, auth)); server.AddStreamHandler(new BakesServerPostHandler(m_BakesService, auth)); } diff --git a/OpenSim/Server/Handlers/Base/ServerConnector.cs b/OpenSim/Server/Handlers/Base/ServerConnector.cs index 72014db..0a4df54 100644 --- a/OpenSim/Server/Handlers/Base/ServerConnector.cs +++ b/OpenSim/Server/Handlers/Base/ServerConnector.cs @@ -72,7 +72,7 @@ namespace OpenSim.Server.Handlers.Base // We call this from our plugin module to get our configuration public IConfig GetConfig() - { + { IConfig config = null; config = ServerUtils.GetConfig(ConfigFile, ConfigName); @@ -96,12 +96,12 @@ namespace OpenSim.Server.Handlers.Base // We get our remote initial configuration for bootstrapping in case // we have no configuration in our main file or in an existing - // modular config file. This is the last resort to bootstrap the + // modular config file. This is the last resort to bootstrap the // configuration, likely a new plugin loading for the first time. private IConfigSource GetConfigSource() { IConfigSource source = null; - + source = ServerUtils.LoadInitialConfig(ConfigURL); if (source == null) diff --git a/OpenSim/Server/Handlers/Grid/GridInfoHandlers.cs b/OpenSim/Server/Handlers/Grid/GridInfoHandlers.cs index 346af32..2aec045 100644 --- a/OpenSim/Server/Handlers/Grid/GridInfoHandlers.cs +++ b/OpenSim/Server/Handlers/Grid/GridInfoHandlers.cs @@ -83,10 +83,10 @@ namespace OpenSim.Server.Handlers.Grid { _info["login"] = String.Format( - "http://127.0.0.1:{0}/", + "http://127.0.0.1:{0}/", netCfg.GetString( "http_listener_port", ConfigSettings.DefaultRegionHttpPort.ToString())); - + IssueWarning(); } else @@ -99,7 +99,7 @@ namespace OpenSim.Server.Handlers.Grid { _log.Warn("[GRID INFO SERVICE]: Cannot get grid info from config source, using minimal defaults"); } - + _log.DebugFormat("[GRID INFO SERVICE]: Grid info service initialized with {0} keys", _info.Count); } @@ -107,7 +107,7 @@ namespace OpenSim.Server.Handlers.Grid { _log.Warn("[GRID INFO SERVICE]: found no [GridInfo] section in your configuration files"); _log.Warn("[GRID INFO SERVICE]: trying to guess sensible defaults, you might want to provide better ones:"); - + foreach (string k in _info.Keys) { _log.WarnFormat("[GRID INFO SERVICE]: {0}: {1}", k, _info[k]); @@ -181,7 +181,7 @@ namespace OpenSim.Server.Handlers.Grid new string[] { "Startup", "Hypergrid" }, String.Empty); if (!String.IsNullOrEmpty(HomeURI)) - map["home"] = OSD.FromString(HomeURI); + map["home"] = OSD.FromString(HomeURI); else // Legacy. Remove soon! { IConfig cfg = m_Config.Configs["LoginService"]; diff --git a/OpenSim/Server/Handlers/Grid/GridServerPostHandler.cs b/OpenSim/Server/Handlers/Grid/GridServerPostHandler.cs index 38629b2..f51c4ee 100644 --- a/OpenSim/Server/Handlers/Grid/GridServerPostHandler.cs +++ b/OpenSim/Server/Handlers/Grid/GridServerPostHandler.cs @@ -126,7 +126,7 @@ namespace OpenSim.Server.Handlers.Grid case "get_grid_extra_features": return GetGridExtraFeatures(request); } - + m_log.DebugFormat("[GRID HANDLER]: unknown method request {0}", method); } catch (Exception e) @@ -590,22 +590,22 @@ namespace OpenSim.Server.Handlers.Grid int flags = m_GridService.GetRegionFlags(scopeID, regionID); // m_log.DebugFormat("[GRID HANDLER]: flags for region {0}: {1}", regionID, flags); - Dictionary result = new Dictionary(); + Dictionary result = new Dictionary(); result["result"] = flags.ToString(); string xmlString = ServerUtils.BuildXmlResponse(result); - + //m_log.DebugFormat("[GRID HANDLER]: resp string: {0}", xmlString); return Util.UTF8NoBomEncoding.GetBytes(xmlString); } - + byte[] GetGridExtraFeatures(Dictionary request) { Dictionary result = new Dictionary (); Dictionary extraFeatures = m_GridService.GetExtraFeatures (); - foreach (string key in extraFeatures.Keys) + foreach (string key in extraFeatures.Keys) { result [key] = extraFeatures [key]; } diff --git a/OpenSim/Server/Handlers/Hypergrid/AgentHandlers.cs b/OpenSim/Server/Handlers/Hypergrid/AgentHandlers.cs index f3d678f..684d1a8 100644 --- a/OpenSim/Server/Handlers/Hypergrid/AgentHandlers.cs +++ b/OpenSim/Server/Handlers/Hypergrid/AgentHandlers.cs @@ -52,7 +52,7 @@ namespace OpenSim.Server.Handlers.Hypergrid public class GatekeeperAgentHandler : OpenSim.Server.Handlers.Simulation.AgentPostHandler { // private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); - + private IGatekeeperService m_GatekeeperService; public GatekeeperAgentHandler(IGatekeeperService gatekeeper, bool proxy) : base("/foreignagent") diff --git a/OpenSim/Server/Handlers/Hypergrid/HGFriendServerConnector.cs b/OpenSim/Server/Handlers/Hypergrid/HGFriendServerConnector.cs index 6c79c60..870a5ef 100644 --- a/OpenSim/Server/Handlers/Hypergrid/HGFriendServerConnector.cs +++ b/OpenSim/Server/Handlers/Hypergrid/HGFriendServerConnector.cs @@ -48,7 +48,7 @@ namespace OpenSim.Server.Handlers.Hypergrid } // Called from standalone configurations - public HGFriendsServerConnector(IConfigSource config, IHttpServer server, string configName, IFriendsSimConnector localConn) + public HGFriendsServerConnector(IConfigSource config, IHttpServer server, string configName, IFriendsSimConnector localConn) : base(config, server, configName) { if (configName != string.Empty) diff --git a/OpenSim/Server/Handlers/Hypergrid/HGFriendsServerPostHandler.cs b/OpenSim/Server/Handlers/Hypergrid/HGFriendsServerPostHandler.cs index 37b47ed..8116050 100644 --- a/OpenSim/Server/Handlers/Hypergrid/HGFriendsServerPostHandler.cs +++ b/OpenSim/Server/Handlers/Hypergrid/HGFriendsServerPostHandler.cs @@ -61,7 +61,7 @@ namespace OpenSim.Server.Handlers.Hypergrid m_UserAgentService = uas; m_FriendsLocalSimConnector = friendsConn; - m_log.DebugFormat("[HGFRIENDS HANDLER]: HGFriendsServerPostHandler is On ({0})", + m_log.DebugFormat("[HGFRIENDS HANDLER]: HGFriendsServerPostHandler is On ({0})", (m_FriendsLocalSimConnector == null ? "robust" : "standalone")); if (m_TheService == null) @@ -105,24 +105,24 @@ namespace OpenSim.Server.Handlers.Hypergrid case "validate_friendship_offered": return ValidateFriendshipOffered(request); - + case "statusnotification": return StatusNotification(request); /* case "friendship_approved": return FriendshipApproved(request); - + case "friendship_denied": return FriendshipDenied(request); - + case "friendship_terminated": return FriendshipTerminated(request); - + case "grant_rights": return GrantRights(request); */ } - + m_log.DebugFormat("[HGFRIENDS HANDLER]: unknown method {0}", method); } catch (Exception e) diff --git a/OpenSim/Server/Handlers/Hypergrid/InstantMessageServerConnector.cs b/OpenSim/Server/Handlers/Hypergrid/InstantMessageServerConnector.cs index 8145a21..63f376d 100644 --- a/OpenSim/Server/Handlers/Hypergrid/InstantMessageServerConnector.cs +++ b/OpenSim/Server/Handlers/Hypergrid/InstantMessageServerConnector.cs @@ -55,7 +55,7 @@ namespace OpenSim.Server.Handlers.Hypergrid public InstantMessageServerConnector(IConfigSource config, IHttpServer server) : this(config, server, (IInstantMessageSimConnector)null) - { + { } public InstantMessageServerConnector(IConfigSource config, IHttpServer server, string configName) : diff --git a/OpenSim/Server/Handlers/Hypergrid/UserAgentServerConnector.cs b/OpenSim/Server/Handlers/Hypergrid/UserAgentServerConnector.cs index 37feabe..394b133 100644 --- a/OpenSim/Server/Handlers/Hypergrid/UserAgentServerConnector.cs +++ b/OpenSim/Server/Handlers/Hypergrid/UserAgentServerConnector.cs @@ -63,14 +63,14 @@ namespace OpenSim.Server.Handlers.Hypergrid public UserAgentServerConnector(IConfigSource config, IHttpServer server) : this(config, server, (IFriendsSimConnector)null) - { + { } public UserAgentServerConnector(IConfigSource config, IHttpServer server, string configName) : this(config, server) { } - + public UserAgentServerConnector(IConfigSource config, IHttpServer server, IFriendsSimConnector friendsConnector) : base(config, server, String.Empty) { diff --git a/OpenSim/Server/Handlers/Inventory/InventoryServerInConnector.cs b/OpenSim/Server/Handlers/Inventory/InventoryServerInConnector.cs index 0bab5aa..e90b869 100644 --- a/OpenSim/Server/Handlers/Inventory/InventoryServerInConnector.cs +++ b/OpenSim/Server/Handlers/Inventory/InventoryServerInConnector.cs @@ -61,7 +61,7 @@ namespace OpenSim.Server.Handlers.Inventory { if (configName != string.Empty) m_ConfigName = configName; - + IConfig serverConfig = config.Configs[m_ConfigName]; if (serverConfig == null) throw new Exception(String.Format("No section '{0}' in config file", m_ConfigName)); @@ -92,7 +92,7 @@ namespace OpenSim.Server.Handlers.Inventory m_httpServer.AddStreamHandler( new RestDeserialiseSecureHandler( "POST", "/GetFolderContent/", GetFolderContent, CheckAuthSession)); - + m_httpServer.AddStreamHandler( new RestDeserialiseSecureHandler( "POST", "/UpdateFolder/", m_InventoryService.UpdateFolder, CheckAuthSession)); @@ -151,7 +151,7 @@ namespace OpenSim.Server.Handlers.Inventory m_httpServer.AddStreamHandler(new InventoryServerMoveItemsHandler(m_InventoryService)); - + // for persistent active gestures m_httpServer.AddStreamHandler( new RestDeserialiseTrustedHandler> diff --git a/OpenSim/Server/Handlers/Inventory/XInventoryInConnector.cs b/OpenSim/Server/Handlers/Inventory/XInventoryInConnector.cs index 96d6451..4400395 100644 --- a/OpenSim/Server/Handlers/Inventory/XInventoryInConnector.cs +++ b/OpenSim/Server/Handlers/Inventory/XInventoryInConnector.cs @@ -293,7 +293,7 @@ namespace OpenSim.Server.Handlers.Inventory result["FID"] = icoll.FolderID.ToString(); result["VERSION"] = icoll.Version.ToString(); Dictionary folders = new Dictionary(); - int i = 0; + int i = 0; if (icoll.Folders != null) { foreach (InventoryFolderBase f in icoll.Folders) @@ -407,7 +407,7 @@ namespace OpenSim.Server.Handlers.Inventory } } result["ITEMS"] = sitems; - + string xmlString = ServerUtils.BuildXmlResponse(result); //m_log.DebugFormat("[XXX]: resp string: {0}", xmlString); diff --git a/OpenSim/Server/Handlers/Land/LandServiceInConnector.cs b/OpenSim/Server/Handlers/Land/LandServiceInConnector.cs index d368bd3..c4b339f 100644 --- a/OpenSim/Server/Handlers/Land/LandServiceInConnector.cs +++ b/OpenSim/Server/Handlers/Land/LandServiceInConnector.cs @@ -54,7 +54,7 @@ namespace OpenSim.Server.Handlers.Land m_log.Error("[LAND IN CONNECTOR]: Land service was not provided"); return; } - + //bool authentication = neighbourConfig.GetBoolean("RequireAuthentication", false); //if (authentication) // m_AuthenticationService = scene.RequestModuleInterface(); diff --git a/OpenSim/Server/Handlers/Login/LLLoginHandlers.cs b/OpenSim/Server/Handlers/Login/LLLoginHandlers.cs index 5d672c3..072429a 100644 --- a/OpenSim/Server/Handlers/Login/LLLoginHandlers.cs +++ b/OpenSim/Server/Handlers/Login/LLLoginHandlers.cs @@ -53,7 +53,7 @@ namespace OpenSim.Server.Handlers.Login private ILoginService m_LocalService; private bool m_Proxy; - + public LLLoginHandlers(ILoginService service, bool hasProxy) { @@ -136,7 +136,7 @@ namespace OpenSim.Server.Handlers.Login bool LibOMVclient = false; if (request.Params.Count > 4 && (string)request.Params[4] == "gridproxy") LibOMVclient = true; - + LoginResponse reply = null; reply = m_LocalService.Login(first, last, passwd, startLocation, scopeID, clientVersion, channel, mac, id0, remoteClient, LibOMVclient); @@ -279,11 +279,11 @@ namespace OpenSim.Server.Handlers.Login sock.Close("success"); } }; - + sock.HandshakeAndUpgrade(); } - + private XmlRpcResponse FailedXMLRPCResponse() { diff --git a/OpenSim/Server/Handlers/Login/LLLoginServiceInConnector.cs b/OpenSim/Server/Handlers/Login/LLLoginServiceInConnector.cs index f60e892..56ac3c2 100644 --- a/OpenSim/Server/Handlers/Login/LLLoginServiceInConnector.cs +++ b/OpenSim/Server/Handlers/Login/LLLoginServiceInConnector.cs @@ -98,7 +98,7 @@ namespace OpenSim.Server.Handlers.Login m_DosProtectionOptions.ForgetTimeSpan = TimeSpan.FromMilliseconds(serverConfig.GetInt("DOSForgiveClientAfterMS", 120000)); m_DosProtectionOptions.ReportingName = "LOGINDOSPROTECTION"; - + return loginService; } @@ -106,7 +106,7 @@ namespace OpenSim.Server.Handlers.Login private void InitializeHandlers(IHttpServer server) { LLLoginHandlers loginHandlers = new LLLoginHandlers(m_LoginService, m_Proxy); - server.AddXmlRPCHandler("login_to_simulator", + server.AddXmlRPCHandler("login_to_simulator", new XmlRpcBasicDOSProtector(loginHandlers.HandleXMLRPCLogin,loginHandlers.HandleXMLRPCLoginBlocked, m_DosProtectionOptions).Process, false); server.AddXmlRPCHandler("set_login_level", loginHandlers.HandleXMLRPCSetLoginLevel, false); diff --git a/OpenSim/Server/Handlers/Map/MapAddServerConnector.cs b/OpenSim/Server/Handlers/Map/MapAddServerConnector.cs index 38dfffc..7611f53 100644 --- a/OpenSim/Server/Handlers/Map/MapAddServerConnector.cs +++ b/OpenSim/Server/Handlers/Map/MapAddServerConnector.cs @@ -148,7 +148,7 @@ namespace OpenSim.Server.Handlers.MapImage } else { - m_log.WarnFormat("[MAP IMAGE HANDLER]: IP address {0} may be rogue. Region not found at coordinates {1}-{2}", + m_log.WarnFormat("[MAP IMAGE HANDLER]: IP address {0} may be rogue. Region not found at coordinates {1}-{2}", ipAddr, x, y); return FailureResult("Region not found at given coordinates"); } diff --git a/OpenSim/Server/Handlers/Map/MapRemoveServerConnector.cs b/OpenSim/Server/Handlers/Map/MapRemoveServerConnector.cs index 4f8f7e1..f292b95 100644 --- a/OpenSim/Server/Handlers/Map/MapRemoveServerConnector.cs +++ b/OpenSim/Server/Handlers/Map/MapRemoveServerConnector.cs @@ -141,7 +141,7 @@ namespace OpenSim.Server.Handlers.MapImage } else { - m_log.WarnFormat("[MAP IMAGE HANDLER]: IP address {0} may be rogue. Region not found at coordinates {1}-{2}", + m_log.WarnFormat("[MAP IMAGE HANDLER]: IP address {0} may be rogue. Region not found at coordinates {1}-{2}", ipAddr, x, y); return FailureResult("Region not found at given coordinates"); } diff --git a/OpenSim/Server/Handlers/Neighbour/NeighbourHandlers.cs b/OpenSim/Server/Handlers/Neighbour/NeighbourHandlers.cs index 3525a01..e3ee467 100644 --- a/OpenSim/Server/Handlers/Neighbour/NeighbourHandlers.cs +++ b/OpenSim/Server/Handlers/Neighbour/NeighbourHandlers.cs @@ -150,7 +150,7 @@ namespace OpenSim.Server.Handlers.Neighbour // Finally! GridRegion thisRegion = m_NeighbourService.HelloNeighbour(regionhandle, aRegion); - + OSDMap resp = new OSDMap(1); if (thisRegion != null) diff --git a/OpenSim/Server/Handlers/Neighbour/NeighbourServiceInConnector.cs b/OpenSim/Server/Handlers/Neighbour/NeighbourServiceInConnector.cs index ac2e75f..65ac4e6 100644 --- a/OpenSim/Server/Handlers/Neighbour/NeighbourServiceInConnector.cs +++ b/OpenSim/Server/Handlers/Neighbour/NeighbourServiceInConnector.cs @@ -55,7 +55,7 @@ namespace OpenSim.Server.Handlers.Neighbour m_log.Error("[NEIGHBOUR IN CONNECTOR]: neighbour service was not provided"); return; } - + //bool authentication = neighbourConfig.GetBoolean("RequireAuthentication", false); //if (authentication) // m_AuthenticationService = scene.RequestModuleInterface(); diff --git a/OpenSim/Server/Handlers/Presence/PresenceServerPostHandler.cs b/OpenSim/Server/Handlers/Presence/PresenceServerPostHandler.cs index 49dbcb5..be16e17 100644 --- a/OpenSim/Server/Handlers/Presence/PresenceServerPostHandler.cs +++ b/OpenSim/Server/Handlers/Presence/PresenceServerPostHandler.cs @@ -158,7 +158,7 @@ namespace OpenSim.Server.Handlers.Presence return FailureResult(); } - + byte[] Report(Dictionary request) { UUID session = UUID.Zero; @@ -241,7 +241,7 @@ namespace OpenSim.Server.Handlers.Presence } string xmlString = ServerUtils.BuildXmlResponse(result); - + //m_log.DebugFormat("[GRID HANDLER]: resp string: {0}", xmlString); return Util.UTF8NoBomEncoding.GetBytes(xmlString); } diff --git a/OpenSim/Server/Handlers/Profiles/UserProfilesConnector.cs b/OpenSim/Server/Handlers/Profiles/UserProfilesConnector.cs index 2dfb862..eecb370 100644 --- a/OpenSim/Server/Handlers/Profiles/UserProfilesConnector.cs +++ b/OpenSim/Server/Handlers/Profiles/UserProfilesConnector.cs @@ -39,8 +39,8 @@ namespace OpenSim.Server.Handlers.Profiles { public class UserProfilesConnector: ServiceConnector { -// static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); - +// static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); + // Our Local Module public IUserProfilesService ServiceModule { @@ -83,7 +83,7 @@ namespace OpenSim.Server.Handlers.Profiles Object[] args = new Object[] { config, ConfigName }; ServiceModule = ServerUtils.LoadPlugin(service, args); - + JsonRpcProfileHandlers handler = new JsonRpcProfileHandlers(ServiceModule); Server.AddJsonRPCHandler("avatarclassifiedsrequest", handler.AvatarClassifiedsRequest); diff --git a/OpenSim/Server/Handlers/Profiles/UserProfilesHandlers.cs b/OpenSim/Server/Handlers/Profiles/UserProfilesHandlers.cs index cac38f5..f23a981 100644 --- a/OpenSim/Server/Handlers/Profiles/UserProfilesHandlers.cs +++ b/OpenSim/Server/Handlers/Profiles/UserProfilesHandlers.cs @@ -48,17 +48,17 @@ namespace OpenSim.Server.Handlers static readonly ILog m_log = LogManager.GetLogger( MethodBase.GetCurrentMethod().DeclaringType); - + public IUserProfilesService Service { get; private set; } - + public JsonRpcProfileHandlers(IUserProfilesService service) { Service = service; } - + #region Classifieds /// /// Request avatar's classified ads. @@ -80,17 +80,17 @@ namespace OpenSim.Server.Handlers m_log.DebugFormat ("Classified Request"); return false; } - + OSDMap request = (OSDMap)json["params"]; UUID creatorId = new UUID(request["creatorId"].AsString()); - - + + OSDArray data = (OSDArray) Service.AvatarClassifiedsRequest(creatorId); response.Result = data; - + return true; } - + public bool ClassifiedUpdate(OSDMap json, ref JsonRpcResponse response) { if(!json.ContainsKey("params")) @@ -100,7 +100,7 @@ namespace OpenSim.Server.Handlers m_log.DebugFormat ("Classified Update Request"); return false; } - + string result = string.Empty; UserClassifiedAdd ad = new UserClassifiedAdd(); object Ad = (object)ad; @@ -110,12 +110,12 @@ namespace OpenSim.Server.Handlers response.Result = OSD.SerializeMembers(ad); return true; } - + response.Error.Code = ErrorCode.InternalError; response.Error.Message = string.Format("{0}", result); return false; } - + public bool ClassifiedDelete(OSDMap json, ref JsonRpcResponse response) { if(!json.ContainsKey("params")) @@ -124,10 +124,10 @@ namespace OpenSim.Server.Handlers m_log.DebugFormat ("Classified Delete Request"); return false; } - + OSDMap request = (OSDMap)json["params"]; UUID classifiedId = new UUID(request["classifiedId"].AsString()); - + if (Service.ClassifiedDelete(classifiedId)) return true; @@ -135,7 +135,7 @@ namespace OpenSim.Server.Handlers response.Error.Message = "data error removing record"; return false; } - + public bool ClassifiedInfoRequest(OSDMap json, ref JsonRpcResponse response) { if(!json.ContainsKey("params")) @@ -145,7 +145,7 @@ namespace OpenSim.Server.Handlers m_log.DebugFormat ("Classified Info Request"); return false; } - + string result = string.Empty; UserClassifiedAdd ad = new UserClassifiedAdd(); object Ad = (object)ad; @@ -155,13 +155,13 @@ namespace OpenSim.Server.Handlers response.Result = OSD.SerializeMembers(ad); return true; } - + response.Error.Code = ErrorCode.InternalError; response.Error.Message = string.Format("{0}", result); return false; } #endregion Classifieds - + #region Picks public bool AvatarPicksRequest(OSDMap json, ref JsonRpcResponse response) { @@ -171,17 +171,17 @@ namespace OpenSim.Server.Handlers m_log.DebugFormat ("Avatar Picks Request"); return false; } - + OSDMap request = (OSDMap)json["params"]; UUID creatorId = new UUID(request["creatorId"].AsString()); - - + + OSDArray data = (OSDArray) Service.AvatarPicksRequest(creatorId); response.Result = data; - + return true; } - + public bool PickInfoRequest(OSDMap json, ref JsonRpcResponse response) { if(!json.ContainsKey("params")) @@ -191,7 +191,7 @@ namespace OpenSim.Server.Handlers m_log.DebugFormat ("Avatar Picks Info Request"); return false; } - + string result = string.Empty; UserProfilePick pick = new UserProfilePick(); object Pick = (object)pick; @@ -201,12 +201,12 @@ namespace OpenSim.Server.Handlers response.Result = OSD.SerializeMembers(pick); return true; } - + response.Error.Code = ErrorCode.InternalError; response.Error.Message = string.Format("{0}", result); return false; } - + public bool PicksUpdate(OSDMap json, ref JsonRpcResponse response) { if(!json.ContainsKey("params")) @@ -216,7 +216,7 @@ namespace OpenSim.Server.Handlers m_log.DebugFormat ("Avatar Picks Update Request"); return false; } - + string result = string.Empty; UserProfilePick pick = new UserProfilePick(); object Pick = (object)pick; @@ -226,13 +226,13 @@ namespace OpenSim.Server.Handlers response.Result = OSD.SerializeMembers(pick); return true; } - + response.Error.Code = ErrorCode.InternalError; response.Error.Message = "unable to update pick"; - + return false; } - + public bool PicksDelete(OSDMap json, ref JsonRpcResponse response) { if(!json.ContainsKey("params")) @@ -241,18 +241,18 @@ namespace OpenSim.Server.Handlers m_log.DebugFormat ("Avatar Picks Delete Request"); return false; } - + OSDMap request = (OSDMap)json["params"]; UUID pickId = new UUID(request["pickId"].AsString()); if(Service.PicksDelete(pickId)) return true; - + response.Error.Code = ErrorCode.InternalError; response.Error.Message = "data error removing record"; return false; } #endregion Picks - + #region Notes public bool AvatarNotesRequest(OSDMap json, ref JsonRpcResponse response) { @@ -277,7 +277,7 @@ namespace OpenSim.Server.Handlers response.Error.Message = "Error reading notes"; return false; } - + public bool NotesUpdate(OSDMap json, ref JsonRpcResponse response) { if(!json.ContainsKey("params")) @@ -287,7 +287,7 @@ namespace OpenSim.Server.Handlers m_log.DebugFormat ("Avatar Notes Update Request"); return false; } - + string result = string.Empty; UserProfileNotes note = new UserProfileNotes(); object Notes = (object) note; @@ -300,7 +300,7 @@ namespace OpenSim.Server.Handlers return true; } #endregion Notes - + #region Profile Properties public bool AvatarPropertiesRequest(OSDMap json, ref JsonRpcResponse response) { @@ -311,7 +311,7 @@ namespace OpenSim.Server.Handlers m_log.DebugFormat ("Avatar Properties Request"); return false; } - + string result = string.Empty; UserProfileProperties props = new UserProfileProperties(); object Props = (object)props; @@ -321,12 +321,12 @@ namespace OpenSim.Server.Handlers response.Result = OSD.SerializeMembers(props); return true; } - + response.Error.Code = ErrorCode.InternalError; response.Error.Message = string.Format("{0}", result); return false; } - + public bool AvatarPropertiesUpdate(OSDMap json, ref JsonRpcResponse response) { if(!json.ContainsKey("params")) @@ -336,7 +336,7 @@ namespace OpenSim.Server.Handlers m_log.DebugFormat ("Avatar Properties Update Request"); return false; } - + string result = string.Empty; UserProfileProperties props = new UserProfileProperties(); object Props = (object)props; @@ -346,13 +346,13 @@ namespace OpenSim.Server.Handlers response.Result = OSD.SerializeMembers(props); return true; } - + response.Error.Code = ErrorCode.InternalError; response.Error.Message = string.Format("{0}", result); return false; } #endregion Profile Properties - + #region Interests public bool AvatarInterestsUpdate(OSDMap json, ref JsonRpcResponse response) { @@ -363,7 +363,7 @@ namespace OpenSim.Server.Handlers m_log.DebugFormat ("Avatar Interests Update Request"); return false; } - + string result = string.Empty; UserProfileProperties props = new UserProfileProperties(); object Props = (object)props; @@ -373,7 +373,7 @@ namespace OpenSim.Server.Handlers response.Result = OSD.SerializeMembers(props); return true; } - + response.Error.Code = ErrorCode.InternalError; response.Error.Message = string.Format("{0}", result); return false; @@ -399,7 +399,7 @@ namespace OpenSim.Server.Handlers response.Result = OSD.SerializeMembers(prefs); return true; } - + response.Error.Code = ErrorCode.InternalError; response.Error.Message = string.Format("{0}", result); // m_log.InfoFormat("[PROFILES]: User preferences request error - {0}", response.Error.Message); @@ -415,7 +415,7 @@ namespace OpenSim.Server.Handlers m_log.DebugFormat ("User Preferences Update Request"); return false; } - + string result = string.Empty; UserPreferences prefs = new UserPreferences(); object Prefs = (object)prefs; @@ -425,7 +425,7 @@ namespace OpenSim.Server.Handlers response.Result = OSD.SerializeMembers(prefs); return true; } - + response.Error.Code = ErrorCode.InternalError; response.Error.Message = string.Format("{0}", result); m_log.InfoFormat("[PROFILES]: User preferences update error - {0}", response.Error.Message); @@ -443,13 +443,13 @@ namespace OpenSim.Server.Handlers m_log.DebugFormat ("Avatar Image Assets Request"); return false; } - + OSDMap request = (OSDMap)json["params"]; UUID avatarId = new UUID(request["avatarId"].AsString()); OSDArray data = (OSDArray) Service.AvatarImageAssetsRequest(avatarId); response.Result = data; - + return true; } #endregion Utiltiy @@ -464,7 +464,7 @@ namespace OpenSim.Server.Handlers m_log.DebugFormat ("User Application Service URL Request: No Parameters!"); return false; } - + string result = string.Empty; UserAppData props = new UserAppData(); object Props = (object)props; @@ -475,15 +475,15 @@ namespace OpenSim.Server.Handlers res["result"] = OSD.FromString("success"); res["token"] = OSD.FromString (result); response.Result = res; - + return true; } - + response.Error.Code = ErrorCode.InternalError; response.Error.Message = string.Format("{0}", result); return false; } - + public bool UpdateUserAppData(OSDMap json, ref JsonRpcResponse response) { if(!json.ContainsKey("params")) @@ -493,7 +493,7 @@ namespace OpenSim.Server.Handlers m_log.DebugFormat ("User App Data Update Request"); return false; } - + string result = string.Empty; UserAppData props = new UserAppData(); object Props = (object)props; @@ -503,7 +503,7 @@ namespace OpenSim.Server.Handlers response.Result = OSD.SerializeMembers(props); return true; } - + response.Error.Code = ErrorCode.InternalError; response.Error.Message = string.Format("{0}", result); return false; diff --git a/OpenSim/Server/Handlers/Properties/AssemblyInfo.cs b/OpenSim/Server/Handlers/Properties/AssemblyInfo.cs index 7d3665b..4d6402f 100644 --- a/OpenSim/Server/Handlers/Properties/AssemblyInfo.cs +++ b/OpenSim/Server/Handlers/Properties/AssemblyInfo.cs @@ -2,7 +2,7 @@ using System.Runtime.CompilerServices; using System.Runtime.InteropServices; -// General Information about an assembly is controlled through the following +// General Information about an assembly is controlled through the following // set of attributes. Change these attribute values to modify the information // associated with an assembly. [assembly: AssemblyTitle("OpenSim.Server.Handlers")] @@ -14,8 +14,8 @@ using System.Runtime.InteropServices; [assembly: AssemblyTrademark("")] [assembly: AssemblyCulture("")] -// Setting ComVisible to false makes the types in this assembly not visible -// to COM components. If you need to access a type in this assembly from +// Setting ComVisible to false makes the types in this assembly not visible +// to COM components. If you need to access a type in this assembly from // COM, set the ComVisible attribute to true on that type. [assembly: ComVisible(false)] @@ -25,7 +25,7 @@ using System.Runtime.InteropServices; // Version information for an assembly consists of the following four values: // // Major Version -// Minor Version +// Minor Version // Build Number // Revision // diff --git a/OpenSim/Server/Handlers/Simulation/AgentHandlers.cs b/OpenSim/Server/Handlers/Simulation/AgentHandlers.cs index 364f1fd..4e1f72e 100644 --- a/OpenSim/Server/Handlers/Simulation/AgentHandlers.cs +++ b/OpenSim/Server/Handlers/Simulation/AgentHandlers.cs @@ -190,7 +190,7 @@ namespace OpenSim.Server.Handlers.Simulation { // If there is no version in the packet at all we're looking at 0.6 or // even more ancient. Refuse it. - if(theirVersion == 0f) + if(theirVersion == 0f) { resp["success"] = OSD.FromBoolean(false); resp["reason"] = OSD.FromString("Your region is running a old version of opensim no longer supported. Consider updating it"); @@ -199,8 +199,8 @@ namespace OpenSim.Server.Handlers.Simulation } version = theirVersion; - - if (version < VersionInfo.SimulationServiceVersionAcceptedMin || + + if (version < VersionInfo.SimulationServiceVersionAcceptedMin || version > VersionInfo.SimulationServiceVersionAcceptedMax ) { resp["success"] = OSD.FromBoolean(false); @@ -274,7 +274,7 @@ namespace OpenSim.Server.Handlers.Simulation OSDArray featuresWanted = new OSDArray(); foreach (UUID feature in features) featuresWanted.Add(OSD.FromString(feature.ToString())); - + resp["features"] = featuresWanted; // We must preserve defaults here, otherwise a false "success" will not be put into the JSON map! @@ -460,7 +460,7 @@ namespace OpenSim.Server.Handlers.Simulation source.RegionLocY = Int32.Parse(args["source_y"].AsString()); source.RegionName = args["source_name"].AsString(); source.RegionID = UUID.Parse(args["source_uuid"].AsString()); - + if (args.ContainsKey("source_server_uri")) source.RawServerURI = args["source_server_uri"].AsString(); else diff --git a/OpenSim/Server/Properties/AssemblyInfo.cs b/OpenSim/Server/Properties/AssemblyInfo.cs index ee45e10..6d15078 100644 --- a/OpenSim/Server/Properties/AssemblyInfo.cs +++ b/OpenSim/Server/Properties/AssemblyInfo.cs @@ -2,7 +2,7 @@ using System.Runtime.CompilerServices; using System.Runtime.InteropServices; -// General Information about an assembly is controlled through the following +// General Information about an assembly is controlled through the following // set of attributes. Change these attribute values to modify the information // associated with an assembly. [assembly: AssemblyTitle("Robust")] @@ -14,8 +14,8 @@ using System.Runtime.InteropServices; [assembly: AssemblyTrademark("")] [assembly: AssemblyCulture("")] -// Setting ComVisible to false makes the types in this assembly not visible -// to COM components. If you need to access a type in this assembly from +// Setting ComVisible to false makes the types in this assembly not visible +// to COM components. If you need to access a type in this assembly from // COM, set the ComVisible attribute to true on that type. [assembly: ComVisible(false)] @@ -25,7 +25,7 @@ using System.Runtime.InteropServices; // Version information for an assembly consists of the following four values: // // Major Version -// Minor Version +// Minor Version // Build Number // Revision // diff --git a/OpenSim/Server/ServerMain.cs b/OpenSim/Server/ServerMain.cs index ed5a481..c343044 100644 --- a/OpenSim/Server/ServerMain.cs +++ b/OpenSim/Server/ServerMain.cs @@ -59,7 +59,7 @@ namespace OpenSim.Server ServicePointManager.UseNagleAlgorithm = false; m_Server = new HttpServerBase("R.O.B.U.S.T.", args); - + string registryLocation; IConfig serverConfig = m_Server.Config.Configs["Startup"]; @@ -70,7 +70,7 @@ namespace OpenSim.Server } string connList = serverConfig.GetString("ServiceConnectors", String.Empty); - + registryLocation = serverConfig.GetString("RegistryLocation","."); IConfig servicesConfig = m_Server.Config.Configs["ServiceList"]; -- cgit v1.1