aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/ScriptEngine/YEngine/XMRArray.cs
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--OpenSim/Region/ScriptEngine/YEngine/XMRArray.cs15
1 files changed, 7 insertions, 8 deletions
diff --git a/OpenSim/Region/ScriptEngine/YEngine/XMRArray.cs b/OpenSim/Region/ScriptEngine/YEngine/XMRArray.cs
index 83ccd9b..67348cf 100644
--- a/OpenSim/Region/ScriptEngine/YEngine/XMRArray.cs
+++ b/OpenSim/Region/ScriptEngine/YEngine/XMRArray.cs
@@ -69,15 +69,14 @@ namespace OpenSim.Region.ScriptEngine.Yengine
69 { 69 {
70 this.inst = inst; 70 this.inst = inst;
71 dnary = new SortedDictionary<object, object>(XMRArrayKeyComparer.singleton); 71 dnary = new SortedDictionary<object, object>(XMRArrayKeyComparer.singleton);
72 heapUse = inst.UpdateHeapUse(0, EMPTYHEAP); 72 heapUse = inst.UpdateArraysHeapUse(0, EMPTYHEAP);
73 } 73 }
74 74
75 /* 75
76 ~XMR_Array() 76 ~XMR_Array()
77 { 77 {
78 heapUse = inst.UpdateHeapUse(heapUse, 0); 78 heapUse = inst.UpdateLocalsHeapUse(heapUse, 0);
79 } 79 }
80 */
81 80
82 public static TokenType GetRValType(TokenName name) 81 public static TokenType GetRValType(TokenName name)
83 { 82 {
@@ -123,7 +122,7 @@ namespace OpenSim.Region.ScriptEngine.Yengine
123 { 122 {
124 newheapuse += keysize + HeapTrackerObject.Size(value); 123 newheapuse += keysize + HeapTrackerObject.Size(value);
125 } 124 }
126 heapUse = inst.UpdateHeapUse(heapUse, newheapuse); 125 heapUse = inst.UpdateArraysHeapUse(heapUse, newheapuse);
127 126
128 // Save new value in array, replacing one of same key if there. 127 // Save new value in array, replacing one of same key if there.
129 // null means remove the value, ie, script did array[key] = undef. 128 // null means remove the value, ie, script did array[key] = undef.
@@ -185,7 +184,7 @@ namespace OpenSim.Region.ScriptEngine.Yengine
185 */ 184 */
186 public void __pub_clear() 185 public void __pub_clear()
187 { 186 {
188 heapUse = inst.UpdateHeapUse(heapUse, EMPTYHEAP); 187 heapUse = inst.UpdateArraysHeapUse(heapUse, EMPTYHEAP);
189 dnary.Clear(); 188 dnary.Clear();
190 enumrValid = false; 189 enumrValid = false;
191 arrayValid = 0; 190 arrayValid = 0;
@@ -286,7 +285,7 @@ namespace OpenSim.Region.ScriptEngine.Yengine
286 public delegate object RecvArrayObjDelegate(); 285 public delegate object RecvArrayObjDelegate();
287 public void RecvArrayObj(RecvArrayObjDelegate recvObj) 286 public void RecvArrayObj(RecvArrayObjDelegate recvObj)
288 { 287 {
289 heapUse = inst.UpdateHeapUse(heapUse, EMPTYHEAP); 288 heapUse = inst.UpdateArraysHeapUse(heapUse, EMPTYHEAP);
290 // Cause any enumeration to refill the array from the sorted dictionary. 289 // Cause any enumeration to refill the array from the sorted dictionary.
291 // Since it is a sorted dictionary, any enumerations will be in the same 290 // Since it is a sorted dictionary, any enumerations will be in the same
292 // order as on the sending side. 291 // order as on the sending side.
@@ -301,7 +300,7 @@ namespace OpenSim.Region.ScriptEngine.Yengine
301 object key = FixKey(recvObj()); 300 object key = FixKey(recvObj());
302 object val = recvObj(); 301 object val = recvObj();
303 int htuse = HeapTrackerObject.Size(key) + HeapTrackerObject.Size(val); 302 int htuse = HeapTrackerObject.Size(key) + HeapTrackerObject.Size(val);
304 heapUse = inst.UpdateHeapUse(heapUse, heapUse + htuse); 303 heapUse = inst.UpdateArraysHeapUse(heapUse, heapUse + htuse);
305 dnary.Add(key, val); 304 dnary.Add(key, val);
306 } 305 }
307 } 306 }