Properly lock new separate database accesses

ThreadPoolClientBranch
Justin Clarke Casey 2008-01-21 15:12:00 +00:00
parent 504ae63669
commit 7ca8e28a9a
2 changed files with 118 additions and 112 deletions

View File

@ -1203,6 +1203,8 @@ namespace OpenSim.Framework.Data.MySQL
MainLog.Instance.Verbose("DATASTORE", "Entered StorePrimInventory with prim ID {0}", primID);
lock (m_dataSet)
{
// Find all existing inventory rows for this prim
DataTable dbItems = m_itemsTable;
@ -1271,6 +1273,7 @@ namespace OpenSim.Framework.Data.MySQL
dbItems.Rows.Add(newItemRow);
}
}
}
/***********************************************************************
*

View File

@ -1258,6 +1258,8 @@ namespace OpenSim.Framework.Data.SQLite
MainLog.Instance.Verbose("DATASTORE", "Entered StorePrimInventory with prim ID {0}", primID);
lock (ds)
{
// Find all existing inventory rows for this prim
DataTable dbItems = ds.Tables["primitems"];
@ -1317,6 +1319,7 @@ namespace OpenSim.Framework.Data.SQLite
dbItems.Rows.Add(newItemRow);
}
}
}
/***********************************************************************
*