aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Storage/OpenSim.DataStore.MonoSqlite
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region/Storage/OpenSim.DataStore.MonoSqlite')
-rw-r--r--OpenSim/Region/Storage/OpenSim.DataStore.MonoSqlite/MonoSqliteDataStore.cs21
1 files changed, 3 insertions, 18 deletions
diff --git a/OpenSim/Region/Storage/OpenSim.DataStore.MonoSqlite/MonoSqliteDataStore.cs b/OpenSim/Region/Storage/OpenSim.DataStore.MonoSqlite/MonoSqliteDataStore.cs
index 0eb8412..1882c55 100644
--- a/OpenSim/Region/Storage/OpenSim.DataStore.MonoSqlite/MonoSqliteDataStore.cs
+++ b/OpenSim/Region/Storage/OpenSim.DataStore.MonoSqlite/MonoSqliteDataStore.cs
@@ -122,8 +122,7 @@ namespace OpenSim.DataStore.MonoSqliteStorage
122 public List<SceneObjectGroup> LoadObjects(LLUUID regionUUID) 122 public List<SceneObjectGroup> LoadObjects(LLUUID regionUUID)
123 { 123 {
124 Dictionary<LLUUID, SceneObjectGroup> createdObjects = new Dictionary<LLUUID, SceneObjectGroup>(); 124 Dictionary<LLUUID, SceneObjectGroup> createdObjects = new Dictionary<LLUUID, SceneObjectGroup>();
125 Dictionary<LLUUID, SceneObjectPart> loadedParentlessParts = new Dictionary<LLUUID, SceneObjectPart>(); 125
126
127 List<SceneObjectGroup> retvals = new List<SceneObjectGroup>(); 126 List<SceneObjectGroup> retvals = new List<SceneObjectGroup>();
128 127
129 DataTable prims = ds.Tables["prims"]; 128 DataTable prims = ds.Tables["prims"];
@@ -170,25 +169,11 @@ namespace OpenSim.DataStore.MonoSqliteStorage
170 Console.WriteLine("No shape found for prim in storage, so setting default box shape"); 169 Console.WriteLine("No shape found for prim in storage, so setting default box shape");
171 prim.Shape = BoxShape.Default; 170 prim.Shape = BoxShape.Default;
172 } 171 }
173 if (createdObjects.ContainsKey(new LLUUID(objID))) 172
174 {
175 createdObjects[new LLUUID(objID)].AddPart(prim); 173 createdObjects[new LLUUID(objID)].AddPart(prim);
176 }
177 else
178 {
179 loadedParentlessParts.Add(new LLUUID(objID), prim);
180 }
181 }
182 174
183 foreach (KeyValuePair<LLUUID, SceneObjectPart> kvp in loadedParentlessParts) 175
184 {
185 if (createdObjects.ContainsKey(kvp.Key))
186 {
187 createdObjects[kvp.Key].AddPart(kvp.Value);
188 }
189 } 176 }
190
191 loadedParentlessParts.Clear();
192 } 177 }
193 178
194 MainLog.Instance.Verbose("DATASTORE", "Sqlite - LoadObjects found " + prims.Rows.Count + " primitives"); 179 MainLog.Instance.Verbose("DATASTORE", "Sqlite - LoadObjects found " + prims.Rows.Count + " primitives");