aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim
diff options
context:
space:
mode:
authorMelanie2010-09-26 23:57:06 +0100
committerMelanie2010-09-26 23:57:06 +0100
commit9f17ae580dd2c6000c1f90ad83bb00e1ba097666 (patch)
treefa2fed00e1f2d54150822019caa03ee6dab7e73f /OpenSim
parentTypo fixes (diff)
parentWhen receiving intersim IM, don't let the spoof protection bomb (diff)
downloadopensim-SC_OLD-9f17ae580dd2c6000c1f90ad83bb00e1ba097666.zip
opensim-SC_OLD-9f17ae580dd2c6000c1f90ad83bb00e1ba097666.tar.gz
opensim-SC_OLD-9f17ae580dd2c6000c1f90ad83bb00e1ba097666.tar.bz2
opensim-SC_OLD-9f17ae580dd2c6000c1f90ad83bb00e1ba097666.tar.xz
Merge branch 'master' into careminster-presence-refactor
Diffstat (limited to 'OpenSim')
-rw-r--r--OpenSim/Region/CoreModules/Avatar/InstantMessage/InstantMessageModule.cs3
-rw-r--r--OpenSim/Region/CoreModules/World/Serialiser/SerialiseObjects.cs2
-rw-r--r--OpenSim/Region/CoreModules/World/Serialiser/SerialiseTerrain.cs5
-rw-r--r--OpenSim/Region/CoreModules/World/Serialiser/SerialiserModule.cs10
4 files changed, 11 insertions, 9 deletions
diff --git a/OpenSim/Region/CoreModules/Avatar/InstantMessage/InstantMessageModule.cs b/OpenSim/Region/CoreModules/Avatar/InstantMessage/InstantMessageModule.cs
index d2dc1ab..347708d 100644
--- a/OpenSim/Region/CoreModules/Avatar/InstantMessage/InstantMessageModule.cs
+++ b/OpenSim/Region/CoreModules/Avatar/InstantMessage/InstantMessageModule.cs
@@ -183,7 +183,8 @@ namespace OpenSim.Region.CoreModules.Avatar.InstantMessage
183 183
184 if (m_TransferModule != null) 184 if (m_TransferModule != null)
185 { 185 {
186 im.fromAgentName = client.FirstName + " " + client.LastName; 186 if (client != null)
187 im.fromAgentName = client.FirstName + " " + client.LastName;
187 m_TransferModule.SendInstantMessage(im, 188 m_TransferModule.SendInstantMessage(im,
188 delegate(bool success) 189 delegate(bool success)
189 { 190 {
diff --git a/OpenSim/Region/CoreModules/World/Serialiser/SerialiseObjects.cs b/OpenSim/Region/CoreModules/World/Serialiser/SerialiseObjects.cs
index 5067ebd..328fbf0 100644
--- a/OpenSim/Region/CoreModules/World/Serialiser/SerialiseObjects.cs
+++ b/OpenSim/Region/CoreModules/World/Serialiser/SerialiseObjects.cs
@@ -41,7 +41,7 @@ namespace OpenSim.Region.CoreModules.World.Serialiser
41 41
42 public string WriteToFile(Scene scene, string dir) 42 public string WriteToFile(Scene scene, string dir)
43 { 43 {
44 string targetFileName = dir + "objects.xml"; 44 string targetFileName = Path.Combine(dir, "objects.xml");
45 45
46 SaveSerialisedToFile(targetFileName, scene); 46 SaveSerialisedToFile(targetFileName, scene);
47 47
diff --git a/OpenSim/Region/CoreModules/World/Serialiser/SerialiseTerrain.cs b/OpenSim/Region/CoreModules/World/Serialiser/SerialiseTerrain.cs
index 5cbe66b..c04753d 100644
--- a/OpenSim/Region/CoreModules/World/Serialiser/SerialiseTerrain.cs
+++ b/OpenSim/Region/CoreModules/World/Serialiser/SerialiseTerrain.cs
@@ -28,6 +28,7 @@
28using OpenSim.Region.CoreModules.World.Terrain; 28using OpenSim.Region.CoreModules.World.Terrain;
29using OpenSim.Region.CoreModules.World.Terrain.FileLoaders; 29using OpenSim.Region.CoreModules.World.Terrain.FileLoaders;
30using OpenSim.Region.Framework.Scenes; 30using OpenSim.Region.Framework.Scenes;
31using System.IO;
31 32
32namespace OpenSim.Region.CoreModules.World.Serialiser 33namespace OpenSim.Region.CoreModules.World.Serialiser
33{ 34{
@@ -38,7 +39,7 @@ namespace OpenSim.Region.CoreModules.World.Serialiser
38 public string WriteToFile(Scene scene, string dir) 39 public string WriteToFile(Scene scene, string dir)
39 { 40 {
40 ITerrainLoader fileSystemExporter = new RAW32(); 41 ITerrainLoader fileSystemExporter = new RAW32();
41 string targetFileName = dir + "heightmap.r32"; 42 string targetFileName = Path.Combine(dir, "heightmap.r32");
42 43
43 lock (scene.Heightmap) 44 lock (scene.Heightmap)
44 { 45 {
@@ -50,4 +51,4 @@ namespace OpenSim.Region.CoreModules.World.Serialiser
50 51
51 #endregion 52 #endregion
52 } 53 }
53} \ No newline at end of file 54}
diff --git a/OpenSim/Region/CoreModules/World/Serialiser/SerialiserModule.cs b/OpenSim/Region/CoreModules/World/Serialiser/SerialiserModule.cs
index 98fe493..04062b0 100644
--- a/OpenSim/Region/CoreModules/World/Serialiser/SerialiserModule.cs
+++ b/OpenSim/Region/CoreModules/World/Serialiser/SerialiserModule.cs
@@ -48,7 +48,7 @@ namespace OpenSim.Region.CoreModules.World.Serialiser
48 48
49 private Commander m_commander = new Commander("export"); 49 private Commander m_commander = new Commander("export");
50 private List<Scene> m_regions = new List<Scene>(); 50 private List<Scene> m_regions = new List<Scene>();
51 private string m_savedir = "exports" + "/"; 51 private string m_savedir = "exports";
52 private List<IFileSerialiser> m_serialisers = new List<IFileSerialiser>(); 52 private List<IFileSerialiser> m_serialisers = new List<IFileSerialiser>();
53 53
54 #region ISharedRegionModule Members 54 #region ISharedRegionModule Members
@@ -192,14 +192,14 @@ namespace OpenSim.Region.CoreModules.World.Serialiser
192 } 192 }
193 } 193 }
194 194
195 TextWriter regionInfoWriter = new StreamWriter(saveDir + "README.TXT"); 195 TextWriter regionInfoWriter = new StreamWriter(Path.Combine(saveDir, "README.TXT"));
196 regionInfoWriter.WriteLine("Region Name: " + scene.RegionInfo.RegionName); 196 regionInfoWriter.WriteLine("Region Name: " + scene.RegionInfo.RegionName);
197 regionInfoWriter.WriteLine("Region ID: " + scene.RegionInfo.RegionID.ToString()); 197 regionInfoWriter.WriteLine("Region ID: " + scene.RegionInfo.RegionID.ToString());
198 regionInfoWriter.WriteLine("Backup Time: UTC " + DateTime.UtcNow.ToString()); 198 regionInfoWriter.WriteLine("Backup Time: UTC " + DateTime.UtcNow.ToString());
199 regionInfoWriter.WriteLine("Serialise Version: 0.1"); 199 regionInfoWriter.WriteLine("Serialise Version: 0.1");
200 regionInfoWriter.Close(); 200 regionInfoWriter.Close();
201 201
202 TextWriter manifestWriter = new StreamWriter(saveDir + "region.manifest"); 202 TextWriter manifestWriter = new StreamWriter(Path.Combine(saveDir, "region.manifest"));
203 foreach (string line in results) 203 foreach (string line in results)
204 { 204 {
205 manifestWriter.WriteLine(line); 205 manifestWriter.WriteLine(line);
@@ -231,7 +231,7 @@ namespace OpenSim.Region.CoreModules.World.Serialiser
231 if (region.RegionInfo.RegionName == (string) args[0]) 231 if (region.RegionInfo.RegionName == (string) args[0])
232 { 232 {
233 // List<string> results = SerialiseRegion(region, m_savedir + region.RegionInfo.RegionID.ToString() + "/"); 233 // List<string> results = SerialiseRegion(region, m_savedir + region.RegionInfo.RegionID.ToString() + "/");
234 SerialiseRegion(region, m_savedir + region.RegionInfo.RegionID.ToString() + "/"); 234 SerialiseRegion(region, Path.Combine(m_savedir, region.RegionInfo.RegionID.ToString()));
235 } 235 }
236 } 236 }
237 } 237 }
@@ -241,7 +241,7 @@ namespace OpenSim.Region.CoreModules.World.Serialiser
241 foreach (Scene region in m_regions) 241 foreach (Scene region in m_regions)
242 { 242 {
243 // List<string> results = SerialiseRegion(region, m_savedir + region.RegionInfo.RegionID.ToString() + "/"); 243 // List<string> results = SerialiseRegion(region, m_savedir + region.RegionInfo.RegionID.ToString() + "/");
244 SerialiseRegion(region, m_savedir + region.RegionInfo.RegionID.ToString() + "/"); 244 SerialiseRegion(region, Path.Combine(m_savedir, region.RegionInfo.RegionID.ToString()));
245 } 245 }
246 } 246 }
247 247