0
0
Fork 0
mirror of https://github.com/GreemDev/Ryujinx.git synced 2024-12-22 23:55:47 +00:00

Handle exceptions when checking user data directory for symlink (#6304)

Co-authored-by: jcm <butt@butts.com>
This commit is contained in:
jcm 2024-02-11 17:10:21 -06:00 committed by GitHub
parent 946633276b
commit 904a5ffcb4
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -233,8 +233,15 @@ namespace Ryujinx.Common.Configuration
// Should be removed, when the existence of the old directory isn't checked anymore.
private static bool IsPathSymlink(string path)
{
FileAttributes attributes = File.GetAttributes(path);
return (attributes & FileAttributes.ReparsePoint) == FileAttributes.ReparsePoint;
try
{
FileAttributes attributes = File.GetAttributes(path);
return (attributes & FileAttributes.ReparsePoint) == FileAttributes.ReparsePoint;
}
catch
{
return false;
}
}
[SupportedOSPlatform("macos")]