aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Framework/Data.SQLite/SQLiteRegionData.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Framework/Data.SQLite/SQLiteRegionData.cs')
-rw-r--r--OpenSim/Framework/Data.SQLite/SQLiteRegionData.cs25
1 files changed, 14 insertions, 11 deletions
diff --git a/OpenSim/Framework/Data.SQLite/SQLiteRegionData.cs b/OpenSim/Framework/Data.SQLite/SQLiteRegionData.cs
index 94c05e1..1364d3e 100644
--- a/OpenSim/Framework/Data.SQLite/SQLiteRegionData.cs
+++ b/OpenSim/Framework/Data.SQLite/SQLiteRegionData.cs
@@ -1283,19 +1283,22 @@ namespace OpenSim.Framework.Data.SQLite
1283 1283
1284 // Eliminate rows from the deletion set which already exist for this prim's inventory 1284 // Eliminate rows from the deletion set which already exist for this prim's inventory
1285 // TODO Very temporary, need to take account of simple metadata changes soon 1285 // TODO Very temporary, need to take account of simple metadata changes soon
1286 foreach (LLUUID itemId in items.Keys) 1286 lock (items)
1287 { 1287 {
1288 String rawItemId = itemId.ToString(); 1288 foreach (LLUUID itemId in items.Keys)
1289
1290 if (dbItemsToRemove.ContainsKey(rawItemId))
1291 {
1292 dbItemsToRemove.Remove(rawItemId);
1293 }
1294 else
1295 { 1289 {
1296 itemsToAdd.Add(items[itemId]); 1290 String rawItemId = itemId.ToString();
1297 } 1291
1298 } 1292 if (dbItemsToRemove.ContainsKey(rawItemId))
1293 {
1294 dbItemsToRemove.Remove(rawItemId);
1295 }
1296 else
1297 {
1298 itemsToAdd.Add(items[itemId]);
1299 }
1300 }
1301 }
1299 1302
1300 // Delete excess rows 1303 // Delete excess rows
1301 foreach (DataRow row in dbItemsToRemove.Values) 1304 foreach (DataRow row in dbItemsToRemove.Values)