_lock.AcquireWriterLock (-1); \r
try {\r
foreach (ExpiresEntry entry in removeList) { \r
+ ExpiresEntry e = entry;\r
int id = entry.Entry.ExpiresIndex;\r
\r
//push the index for reuse\r
\r
if (entry.Entry.ExpiresBucket == _byteID) {\r
// add to our flush list\r
- flushList.Add (entry.Entry);\r
+ flushList.Add (e.Entry);\r
\r
// Remove from bucket\r
- entry.Entry.ExpiresBucket = CacheEntry.NoBucketHash;\r
- entry.Entry.ExpiresIndex = CacheEntry.NoIndexInBucket;\r
+ e.Entry.ExpiresBucket = CacheEntry.NoBucketHash;\r
+ e.Entry.ExpiresIndex = CacheEntry.NoIndexInBucket;\r
} \r
\r
- entry.Entry = null;\r
+ e.Entry = null;\r
\r
// Entries is structs, put it back\r
- _arrEntries [id] = objEntry;\r
+ _arrEntries [id] = e;\r
}\r
}\r
finally {\r