mirror of
https://github.com/ppy/osu.git
synced 2024-11-11 11:20:04 +08:00
Move exists
check inside retry operation
Might help?
This commit is contained in:
parent
1c1ee22aa7
commit
a8416f3572
@ -307,17 +307,17 @@ namespace osu.Game.Database
|
||||
// Realms.Exceptions.RealmException: SetEndOfFile() failed: unknown error (1224)
|
||||
//
|
||||
// which can occur due to file handles still being open by a previous instance.
|
||||
if (storage.Exists(Filename))
|
||||
//
|
||||
// If this fails we allow it to block game startup. It's better than any alternative we can offer.
|
||||
FileUtils.AttemptOperation(() =>
|
||||
{
|
||||
// If this fails we allow it to block game startup.
|
||||
// It's better than any alternative we can offer.
|
||||
FileUtils.AttemptOperation(() =>
|
||||
if (storage.Exists(Filename))
|
||||
{
|
||||
using (var _ = storage.GetStream(Filename, FileAccess.ReadWrite))
|
||||
{
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
string newerVersionFilename = $"{Filename.Replace(realm_extension, string.Empty)}_newer_version{realm_extension}";
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user