mirror of
https://github.com/PCSX2/pcsx2.git
synced 2026-11-14 18:20:36 +01:00
GsDumpFinder: fix error when dir not found
This commit is contained in:
1 parent
b19804190e
commit
ba2efec983
1 file changed
+11
-1
@@ -38,7 +38,17 @@ namespace GSDumpGUI.Forms.Helper
|
||||
|
||||
public IEnumerable<GsDumpFile> GetValidGsdxDumps(DirectoryInfo directory)
|
||||
{
|
||||
var dumps = directory.GetFiles("*.gs", SearchOption.TopDirectoryOnly);
|
||||
var dumps = new FileInfo[0];
|
||||
|
||||
try
|
||||
{
|
||||
dumps = directory.GetFiles("*.gs", SearchOption.TopDirectoryOnly);
|
||||
}
|
||||
catch (DirectoryNotFoundException)
|
||||
{
|
||||
_logger.Warning($"Failed to open folder '{directory}'.");
|
||||
yield break;
|
||||
}
|
||||
|
||||
foreach (var dump in dumps)
|
||||
{
|
||||
|
||||
Reference in new issue
Block a user