Fix some hard links not being created due to missing directory structure

Co-authored-by: Bartłomiej Dach <dach.bartlomiej@gmail.com>
This commit is contained in:
Dean Herbert
2022-12-15 14:17:28 +09:00
committed by GitHub
parent a3c3112f89
commit 6bf1477939

View File

@ -66,7 +66,7 @@ namespace osu.Game.Database
if (RuntimeInfo.OS == RuntimeInfo.Platform.Windows && data is FileStream fs && preferHardLinks)
{
// attempt to do a fast hard link rather than copy.
if (HardLinkHelper.CreateHardLink(Storage.GetFullPath(file.GetStoragePath()), fs.Name, IntPtr.Zero))
if (HardLinkHelper.CreateHardLink(Storage.GetFullPath(file.GetStoragePath(), true), fs.Name, IntPtr.Zero))
return;
}