diff options
Attempt to fix mantis issue #82, taking prims into inventory and then rezzing them in another region.
Diffstat (limited to 'OpenSim/Framework/Communications/Cache/CachedUserInfo.cs')
-rw-r--r-- | OpenSim/Framework/Communications/Cache/CachedUserInfo.cs | 20 |
1 files changed, 16 insertions, 4 deletions
diff --git a/OpenSim/Framework/Communications/Cache/CachedUserInfo.cs b/OpenSim/Framework/Communications/Cache/CachedUserInfo.cs index 8fbc3fd..81ee29b 100644 --- a/OpenSim/Framework/Communications/Cache/CachedUserInfo.cs +++ b/OpenSim/Framework/Communications/Cache/CachedUserInfo.cs | |||
@@ -55,14 +55,20 @@ namespace OpenSim.Framework.Communications.Cache | |||
55 | } | 55 | } |
56 | else if (RootFolder.folderID == folderInfo.parentID) | 56 | else if (RootFolder.folderID == folderInfo.parentID) |
57 | { | 57 | { |
58 | RootFolder.SubFolders.Add(folderInfo.folderID, folderInfo); | 58 | if (!RootFolder.SubFolders.ContainsKey(folderInfo.folderID)) |
59 | { | ||
60 | RootFolder.SubFolders.Add(folderInfo.folderID, folderInfo); | ||
61 | } | ||
59 | } | 62 | } |
60 | else | 63 | else |
61 | { | 64 | { |
62 | InventoryFolderImpl folder = RootFolder.HasSubFolder(folderInfo.parentID); | 65 | InventoryFolderImpl folder = RootFolder.HasSubFolder(folderInfo.parentID); |
63 | if (folder != null) | 66 | if (folder != null) |
64 | { | 67 | { |
65 | folder.SubFolders.Add(folderInfo.folderID, folderInfo); | 68 | if (!folder.SubFolders.ContainsKey(folderInfo.folderID)) |
69 | { | ||
70 | folder.SubFolders.Add(folderInfo.folderID, folderInfo); | ||
71 | } | ||
66 | } | 72 | } |
67 | } | 73 | } |
68 | } | 74 | } |
@@ -74,14 +80,20 @@ namespace OpenSim.Framework.Communications.Cache | |||
74 | { | 80 | { |
75 | if (itemInfo.parentFolderID == RootFolder.folderID) | 81 | if (itemInfo.parentFolderID == RootFolder.folderID) |
76 | { | 82 | { |
77 | RootFolder.Items.Add(itemInfo.inventoryID, itemInfo); | 83 | if (!RootFolder.Items.ContainsKey(itemInfo.inventoryID)) |
84 | { | ||
85 | RootFolder.Items.Add(itemInfo.inventoryID, itemInfo); | ||
86 | } | ||
78 | } | 87 | } |
79 | else | 88 | else |
80 | { | 89 | { |
81 | InventoryFolderImpl folder = RootFolder.HasSubFolder(itemInfo.parentFolderID); | 90 | InventoryFolderImpl folder = RootFolder.HasSubFolder(itemInfo.parentFolderID); |
82 | if (folder != null) | 91 | if (folder != null) |
83 | { | 92 | { |
84 | folder.Items.Add(itemInfo.inventoryID, itemInfo); | 93 | if (!folder.Items.ContainsKey(itemInfo.inventoryID)) |
94 | { | ||
95 | folder.Items.Add(itemInfo.inventoryID, itemInfo); | ||
96 | } | ||
85 | } | 97 | } |
86 | } | 98 | } |
87 | } | 99 | } |