From a41cd1d0695c01e4096fa0b7696b415a4c7455fc Mon Sep 17 00:00:00 2001 From: John Hurliman Date: Fri, 23 Oct 2009 13:14:29 -0700 Subject: * Unregister Mono.Addins event handlers in PluginLoader.Dispose() and always handle PluginLoader with the using pattern. This freed up 121,634,796 bytes on my system * Avoid allocating an Action object every round of the OutgoingPacketHandler * Removed unnecessary semi-colon endings from OpenSim.ini.example [InterestManagement] section --- OpenSim/Grid/GridServer/GridServerBase.cs | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'OpenSim/Grid/GridServer/GridServerBase.cs') diff --git a/OpenSim/Grid/GridServer/GridServerBase.cs b/OpenSim/Grid/GridServer/GridServerBase.cs index d63ac2e..113d5c8 100644 --- a/OpenSim/Grid/GridServer/GridServerBase.cs +++ b/OpenSim/Grid/GridServer/GridServerBase.cs @@ -115,11 +115,11 @@ namespace OpenSim.Grid.GridServer protected virtual void LoadPlugins() { - PluginLoader loader = - new PluginLoader(new GridPluginInitialiser(this)); - - loader.Load("/OpenSim/GridServer"); - m_plugins = loader.Plugins; + using (PluginLoader loader = new PluginLoader(new GridPluginInitialiser(this))) + { + loader.Load("/OpenSim/GridServer"); + m_plugins = loader.Plugins; + } } public override void ShutdownSpecific() -- cgit v1.1 From 2c34619aea074446e53dde80d397973075914bac Mon Sep 17 00:00:00 2001 From: John Hurliman Date: Fri, 23 Oct 2009 14:22:21 -0700 Subject: * Changed various modules to not initialize timers unless the module is initialized. Ideally, the timers would not initialize unless the module was actually enabled, but Melanie's work on configuring module loading from a config file should make that unnecessary * Wrapped the Bitmap class used to generate the world map tile in a using statement to dispose of it after the JPEG2000 data is created --- OpenSim/Grid/GridServer/GridServerBase.cs | 1 - 1 file changed, 1 deletion(-) (limited to 'OpenSim/Grid/GridServer/GridServerBase.cs') diff --git a/OpenSim/Grid/GridServer/GridServerBase.cs b/OpenSim/Grid/GridServer/GridServerBase.cs index 113d5c8..9b0d7ea 100644 --- a/OpenSim/Grid/GridServer/GridServerBase.cs +++ b/OpenSim/Grid/GridServer/GridServerBase.cs @@ -29,7 +29,6 @@ using System; using System.Collections.Generic; using System.IO; using System.Reflection; -using System.Timers; using log4net; using Nini.Config; using OpenSim.Framework; -- cgit v1.1