[System.Runtime.Caching] Add missing locking when accessing cache entries
authorAlexander Köplinger <alex.koeplinger@outlook.com>
Thu, 10 Dec 2015 13:53:27 +0000 (14:53 +0100)
committerAlexander Köplinger <alex.koeplinger@outlook.com>
Thu, 10 Dec 2015 13:56:05 +0000 (14:56 +0100)
commit7a79d9d7e679fb4f7e0f32025ffcba9321e7849f
tree1ad3e5a33a4327333d10d1686c895cc468822935
parent0434dc02352870434ccc4226021d7877d2c9df8c
[System.Runtime.Caching] Add missing locking when accessing cache entries

The "entries" collection in CacheEntryCollection can be modified while we're enumerating it,
which is not allowed. Add locking in FlushItems() to prevent this.
mcs/class/System.Runtime.Caching/ReferenceSources/CacheEntryCollection.cs