no need to clone something Idisposable when we just want to see values

This commit is contained in:
UbitUmarov
2020-05-12 18:58:07 +01:00
parent d613287a77
commit 51bc19f1ab
2 changed files with 5 additions and 12 deletions

View File

@@ -267,12 +267,8 @@ namespace OpenSim.Framework
public List<TaskInventoryItem> GetItems()
{
var ret = new List<TaskInventoryItem>(this.Count);
m_itemLock.EnterReadLock();
foreach (TaskInventoryItem it in Values)
{
ret.Add(it);
}
var ret = new List<TaskInventoryItem>(Values);
m_itemLock.ExitReadLock();
return ret;
}