aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/CoreModules/World
diff options
context:
space:
mode:
authorDiva Canto2010-12-10 23:16:47 -0800
committerDiva Canto2010-12-10 23:16:47 -0800
commit18b10fab609787bc1bb1284fe174a900ab588e49 (patch)
tree0d612c1c63927d9a59f34e3129031033526c2edd /OpenSim/Region/CoreModules/World
parentAnother stab at mantis #5256 (diff)
parentRemove the restriction that you have to be logged in when loading/saving iars (diff)
downloadopensim-SC_OLD-18b10fab609787bc1bb1284fe174a900ab588e49.zip
opensim-SC_OLD-18b10fab609787bc1bb1284fe174a900ab588e49.tar.gz
opensim-SC_OLD-18b10fab609787bc1bb1284fe174a900ab588e49.tar.bz2
opensim-SC_OLD-18b10fab609787bc1bb1284fe174a900ab588e49.tar.xz
Merge branch 'master' of ssh://opensimulator.org/var/git/opensim
Diffstat (limited to 'OpenSim/Region/CoreModules/World')
-rw-r--r--OpenSim/Region/CoreModules/World/Archiver/ArchiveWriteRequestExecution.cs3
-rw-r--r--OpenSim/Region/CoreModules/World/Archiver/ArchiveWriteRequestPreparation.cs64
-rw-r--r--OpenSim/Region/CoreModules/World/Archiver/ArchiverModule.cs2
3 files changed, 34 insertions, 35 deletions
diff --git a/OpenSim/Region/CoreModules/World/Archiver/ArchiveWriteRequestExecution.cs b/OpenSim/Region/CoreModules/World/Archiver/ArchiveWriteRequestExecution.cs
index f8a599a..9ec4ebe 100644
--- a/OpenSim/Region/CoreModules/World/Archiver/ArchiveWriteRequestExecution.cs
+++ b/OpenSim/Region/CoreModules/World/Archiver/ArchiveWriteRequestExecution.cs
@@ -136,14 +136,13 @@ namespace OpenSim.Region.CoreModules.World.Archiver
136 ms.Close(); 136 ms.Close();
137 137
138 m_log.InfoFormat("[ARCHIVER]: Added terrain information to archive."); 138 m_log.InfoFormat("[ARCHIVER]: Added terrain information to archive.");
139
140 139
141 // Write out scene object metadata 140 // Write out scene object metadata
142 foreach (SceneObjectGroup sceneObject in m_sceneObjects) 141 foreach (SceneObjectGroup sceneObject in m_sceneObjects)
143 { 142 {
144 //m_log.DebugFormat("[ARCHIVER]: Saving {0} {1}, {2}", entity.Name, entity.UUID, entity.GetType()); 143 //m_log.DebugFormat("[ARCHIVER]: Saving {0} {1}, {2}", entity.Name, entity.UUID, entity.GetType());
145 144
146 string serializedObject = m_serialiser.SerializeGroupToXml2(sceneObject, m_options); 145 string serializedObject = m_serialiser.SerializeGroupToXml2(sceneObject, m_options);
147 m_archiveWriter.WriteFile(ArchiveHelpers.CreateObjectPath(sceneObject), serializedObject); 146 m_archiveWriter.WriteFile(ArchiveHelpers.CreateObjectPath(sceneObject), serializedObject);
148 } 147 }
149 148
diff --git a/OpenSim/Region/CoreModules/World/Archiver/ArchiveWriteRequestPreparation.cs b/OpenSim/Region/CoreModules/World/Archiver/ArchiveWriteRequestPreparation.cs
index 0699407..f2d487e 100644
--- a/OpenSim/Region/CoreModules/World/Archiver/ArchiveWriteRequestPreparation.cs
+++ b/OpenSim/Region/CoreModules/World/Archiver/ArchiveWriteRequestPreparation.cs
@@ -58,7 +58,7 @@ namespace OpenSim.Region.CoreModules.World.Archiver
58 /// <summary> 58 /// <summary>
59 /// The maximum major version of OAR that we can write. 59 /// The maximum major version of OAR that we can write.
60 /// </summary> 60 /// </summary>
61 public static int MAX_MAJOR_VERSION = 1; 61 public static int MAX_MAJOR_VERSION = 0;
62 62
63 protected Scene m_scene; 63 protected Scene m_scene;
64 protected Stream m_saveStream; 64 protected Stream m_saveStream;
@@ -206,37 +206,37 @@ namespace OpenSim.Region.CoreModules.World.Archiver
206 /// <returns></returns> 206 /// <returns></returns>
207 public static string CreateControlFile(Dictionary<string, object> options) 207 public static string CreateControlFile(Dictionary<string, object> options)
208 { 208 {
209 int majorVersion = MAX_MAJOR_VERSION, minorVersion = 0; 209 int majorVersion = MAX_MAJOR_VERSION, minorVersion = 5;
210 210//
211 if (options.ContainsKey("version")) 211// if (options.ContainsKey("version"))
212 { 212// {
213 string[] parts = options["version"].ToString().Split('.'); 213// string[] parts = options["version"].ToString().Split('.');
214 if (parts.Length >= 1) 214// if (parts.Length >= 1)
215 { 215// {
216 majorVersion = Int32.Parse(parts[0]); 216// majorVersion = Int32.Parse(parts[0]);
217 217//
218 if (parts.Length >= 2) 218// if (parts.Length >= 2)
219 minorVersion = Int32.Parse(parts[1]); 219// minorVersion = Int32.Parse(parts[1]);
220 } 220// }
221 } 221// }
222 222//
223 if (majorVersion < MIN_MAJOR_VERSION || majorVersion > MAX_MAJOR_VERSION) 223// if (majorVersion < MIN_MAJOR_VERSION || majorVersion > MAX_MAJOR_VERSION)
224 { 224// {
225 throw new Exception( 225// throw new Exception(
226 string.Format( 226// string.Format(
227 "OAR version number for save must be between {0} and {1}", 227// "OAR version number for save must be between {0} and {1}",
228 MIN_MAJOR_VERSION, MAX_MAJOR_VERSION)); 228// MIN_MAJOR_VERSION, MAX_MAJOR_VERSION));
229 } 229// }
230 else if (majorVersion == MAX_MAJOR_VERSION) 230// else if (majorVersion == MAX_MAJOR_VERSION)
231 { 231// {
232 // Force 1.0 232// // Force 1.0
233 minorVersion = 0; 233// minorVersion = 0;
234 } 234// }
235 else if (majorVersion == MIN_MAJOR_VERSION) 235// else if (majorVersion == MIN_MAJOR_VERSION)
236 { 236// {
237 // Force 0.4 237// // Force 0.4
238 minorVersion = 4; 238// minorVersion = 4;
239 } 239// }
240 240
241 m_log.InfoFormat("[ARCHIVER]: Creating version {0}.{1} OAR", majorVersion, minorVersion); 241 m_log.InfoFormat("[ARCHIVER]: Creating version {0}.{1} OAR", majorVersion, minorVersion);
242 //if (majorVersion == 1) 242 //if (majorVersion == 1)
diff --git a/OpenSim/Region/CoreModules/World/Archiver/ArchiverModule.cs b/OpenSim/Region/CoreModules/World/Archiver/ArchiverModule.cs
index 2d7244e..9277c59 100644
--- a/OpenSim/Region/CoreModules/World/Archiver/ArchiverModule.cs
+++ b/OpenSim/Region/CoreModules/World/Archiver/ArchiverModule.cs
@@ -125,7 +125,7 @@ namespace OpenSim.Region.CoreModules.World.Archiver
125 Dictionary<string, object> options = new Dictionary<string, object>(); 125 Dictionary<string, object> options = new Dictionary<string, object>();
126 126
127 OptionSet ops = new OptionSet(); 127 OptionSet ops = new OptionSet();
128 ops.Add("v|version=", delegate(string v) { options["version"] = v; }); 128// ops.Add("v|version=", delegate(string v) { options["version"] = v; });
129 ops.Add("p|profile=", delegate(string v) { options["profile"] = v; }); 129 ops.Add("p|profile=", delegate(string v) { options["profile"] = v; });
130 130
131 List<string> mainParams = ops.Parse(cmdparams); 131 List<string> mainParams = ops.Parse(cmdparams);