aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Server
diff options
context:
space:
mode:
authorUbitUmarov2018-09-29 17:42:12 +0100
committerUbitUmarov2018-09-29 17:42:12 +0100
commited0e2623b9dd9e12f7660bb067166c294ad8a2ee (patch)
tree6c596402d4063d421cd013fdb03dba3e7509e39c /OpenSim/Server
parentmore on culture issues (diff)
downloadopensim-SC-ed0e2623b9dd9e12f7660bb067166c294ad8a2ee.zip
opensim-SC-ed0e2623b9dd9e12f7660bb067166c294ad8a2ee.tar.gz
opensim-SC-ed0e2623b9dd9e12f7660bb067166c294ad8a2ee.tar.bz2
opensim-SC-ed0e2623b9dd9e12f7660bb067166c294ad8a2ee.tar.xz
add a few more gc collect in some spots
Diffstat (limited to 'OpenSim/Server')
-rw-r--r--OpenSim/Server/Base/ServerUtils.cs12
1 files changed, 7 insertions, 5 deletions
diff --git a/OpenSim/Server/Base/ServerUtils.cs b/OpenSim/Server/Base/ServerUtils.cs
index d0043ba..b020215 100644
--- a/OpenSim/Server/Base/ServerUtils.cs
+++ b/OpenSim/Server/Base/ServerUtils.cs
@@ -204,8 +204,7 @@ namespace OpenSim.Server.Base
204 xw.Flush(); 204 xw.Flush();
205 205
206 ms.Seek(0, SeekOrigin.Begin); 206 ms.Seek(0, SeekOrigin.Begin);
207 byte[] ret = ms.GetBuffer(); 207 byte[] ret = ms.ToArray();
208 Array.Resize(ref ret, (int)ms.Length);
209 208
210 return ret; 209 return ret;
211 } 210 }
@@ -579,9 +578,12 @@ namespace OpenSim.Server.Base
579 // Try to read it 578 // Try to read it
580 try 579 try
581 { 580 {
582 XmlReader r = XmlReader.Create(url); 581 IConfigSource cs;
583 IConfigSource cs = new XmlConfigSource(r); 582 using( XmlReader r = XmlReader.Create(url))
584 source.Merge(cs); 583 {
584 cs = new XmlConfigSource(r);
585 source.Merge(cs);
586 }
585 } 587 }
586 catch (Exception e) 588 catch (Exception e)
587 { 589 {