aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--OpenSim/Region/Framework/Scenes/Scene.PacketHandlers.cs18
1 files changed, 17 insertions, 1 deletions
diff --git a/OpenSim/Region/Framework/Scenes/Scene.PacketHandlers.cs b/OpenSim/Region/Framework/Scenes/Scene.PacketHandlers.cs
index c816790..55b100b 100644
--- a/OpenSim/Region/Framework/Scenes/Scene.PacketHandlers.cs
+++ b/OpenSim/Region/Framework/Scenes/Scene.PacketHandlers.cs
@@ -473,7 +473,7 @@ namespace OpenSim.Region.Framework.Scenes
473 /// <param name="sortOrder"></param> 473 /// <param name="sortOrder"></param>
474 /// <returns>null if the inventory look up failed</returns> 474 /// <returns>null if the inventory look up failed</returns>
475 public InventoryCollection HandleFetchInventoryDescendentsCAPS(UUID agentID, UUID folderID, UUID ownerID, 475 public InventoryCollection HandleFetchInventoryDescendentsCAPS(UUID agentID, UUID folderID, UUID ownerID,
476 bool fetchFolders, bool fetchItems, int sortOrder) 476 bool fetchFolders, bool fetchItems, int sortOrder, out int version)
477 { 477 {
478// m_log.DebugFormat( 478// m_log.DebugFormat(
479// "[INVENTORY CACHE]: Fetching folders ({0}), items ({1}) from {2} for agent {3}", 479// "[INVENTORY CACHE]: Fetching folders ({0}), items ({1}) from {2} for agent {3}",
@@ -487,6 +487,7 @@ namespace OpenSim.Region.Framework.Scenes
487 InventoryFolderImpl fold; 487 InventoryFolderImpl fold;
488 if ((fold = CommsManager.UserProfileCacheService.LibraryRoot.FindFolder(folderID)) != null) 488 if ((fold = CommsManager.UserProfileCacheService.LibraryRoot.FindFolder(folderID)) != null)
489 { 489 {
490 version = 0;
490 InventoryCollection ret = new InventoryCollection(); 491 InventoryCollection ret = new InventoryCollection();
491 ret.Folders = new List<InventoryFolderBase>(); 492 ret.Folders = new List<InventoryFolderBase>();
492 ret.Items = fold.RequestListOfItems(); 493 ret.Items = fold.RequestListOfItems();
@@ -495,6 +496,21 @@ namespace OpenSim.Region.Framework.Scenes
495 } 496 }
496 497
497 InventoryCollection contents = InventoryService.GetFolderContent(agentID, folderID); 498 InventoryCollection contents = InventoryService.GetFolderContent(agentID, folderID);
499
500 if (folderID != UUID.Zero)
501 {
502 InventoryFolderBase containingFolder = new InventoryFolderBase();
503 containingFolder.ID = folderID;
504 containingFolder.Owner = agentID;
505 containingFolder = InventoryService.GetFolder(containingFolder);
506 version = containingFolder.Version;
507 }
508 else
509 {
510 // Lost itemsm don't really need a version
511 version = 1;
512 }
513
498 return contents; 514 return contents;
499 515
500 } 516 }