How long will a thread wait for a race condition in the following scenario?
A file is added to a collection:
lock(mylock)
{
// add to collection
}
It is then removed from the collection in a similiar manner.
If a thread is trying to add to the collection while the service is removing it from the collection, who wins?
Or is that the point of a race condition, you can't predict who wins?