Don't worry about checking FlotsamAssetCache.m_CurrentlyWriting when updating access time.

The majority of updates won't be for anything currently writing and any sharing exception from an actual clash can be caught and ignored anyway.
This commit is contained in:
Justin Clark-Casey (justincc)
2014-12-04 01:46:00 +00:00
parent 5861401faa
commit c36bfdc60f

View File

@@ -256,16 +256,9 @@ namespace OpenSim.Region.CoreModules.Asset
// If the file is already cached, don't cache it, just touch it so access time is updated
if (File.Exists(filename))
{
// We don't really want to know about sharing
// violations here. If the file is locked, then
// the other thread has updated the time for us.
try
{
lock (m_CurrentlyWriting)
{
if (!m_CurrentlyWriting.Contains(filename))
File.SetLastAccessTime(filename, DateTime.Now);
}
File.SetLastAccessTime(filename, DateTime.Now);
}
catch
{