aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/CoreModules/Avatar/Inventory/Archiver/InventoryArchiveReadRequest.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region/CoreModules/Avatar/Inventory/Archiver/InventoryArchiveReadRequest.cs')
-rw-r--r--OpenSim/Region/CoreModules/Avatar/Inventory/Archiver/InventoryArchiveReadRequest.cs20
1 files changed, 19 insertions, 1 deletions
diff --git a/OpenSim/Region/CoreModules/Avatar/Inventory/Archiver/InventoryArchiveReadRequest.cs b/OpenSim/Region/CoreModules/Avatar/Inventory/Archiver/InventoryArchiveReadRequest.cs
index c1df827..2beea8e 100644
--- a/OpenSim/Region/CoreModules/Avatar/Inventory/Archiver/InventoryArchiveReadRequest.cs
+++ b/OpenSim/Region/CoreModules/Avatar/Inventory/Archiver/InventoryArchiveReadRequest.cs
@@ -33,6 +33,7 @@ using System.Reflection;
33using System.Threading; 33using System.Threading;
34using System.Text; 34using System.Text;
35using System.Xml; 35using System.Xml;
36using System.Xml.Linq;
36using log4net; 37using log4net;
37using OpenMetaverse; 38using OpenMetaverse;
38using OpenSim.Framework; 39using OpenSim.Framework;
@@ -133,7 +134,11 @@ namespace OpenSim.Region.CoreModules.Avatar.Inventory.Archiver
133 134
134 while ((data = archive.ReadEntry(out filePath, out entryType)) != null) 135 while ((data = archive.ReadEntry(out filePath, out entryType)) != null)
135 { 136 {
136 if (filePath.StartsWith(ArchiveConstants.ASSETS_PATH)) 137 if (filePath == ArchiveConstants.CONTROL_FILE_PATH)
138 {
139 LoadControlFile(filePath, data);
140 }
141 else if (filePath.StartsWith(ArchiveConstants.ASSETS_PATH))
137 { 142 {
138 if (LoadAsset(filePath, data)) 143 if (LoadAsset(filePath, data))
139 successfulAssetRestores++; 144 successfulAssetRestores++;
@@ -461,5 +466,18 @@ namespace OpenSim.Region.CoreModules.Avatar.Inventory.Archiver
461 return false; 466 return false;
462 } 467 }
463 } 468 }
469
470 /// <summary>
471 /// Load control file
472 /// </summary>
473 /// <param name="path"></param>
474 /// <param name="data"></param>
475 protected void LoadControlFile(string path, byte[] data)
476 {
477 XDocument doc = XDocument.Parse(Encoding.ASCII.GetString(data));
478 XElement archiveElement = doc.Element("archive");
479 int.Parse(archiveElement.Attribute("major_version").Value);
480 int.Parse(archiveElement.Attribute("minor_version").Value);
481 }
464 } 482 }
465} \ No newline at end of file 483} \ No newline at end of file