Skip to content

Commit 14efd85

Browse files
committed
Skip macOS Metadata in rom detection
1 parent 779747f commit 14efd85

1 file changed

Lines changed: 6 additions & 1 deletion

File tree

Source/UI/RomSelectorComponent.cpp

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -243,7 +243,12 @@ void IRomSelectorComponent::AddRomDirectory(const std::filesystem::path &p_roms_
243243
if (entry.is_regular_file())
244244
{
245245
const std::filesystem::path& rom_filename = entry.path().filename();
246-
if(std::find(valid_extensions.begin(), valid_extensions.end(), rom_filename.extension()) != valid_extensions.end())
246+
247+
// Skip macOS metadata
248+
if (rom_filename.string().starts_with("._"))
249+
continue;
250+
251+
if(std::find(valid_extensions.begin(), valid_extensions.end(), rom_filename.extension()) != valid_extensions.end())
247252
{
248253
auto p_rom_info = new SRomInfo(entry);
249254
roms.emplace_back( p_rom_info);

0 commit comments

Comments
 (0)