More conservative unlink error in Hydra

This commit is contained in:
Martin Griffin 2023-06-22 17:17:19 +01:00
parent e8b2eea89d
commit 72bb8b71b6

View File

@ -168,7 +168,11 @@ static void unlink_roms(void)
if (runners[i].rom_path[0])
{
if (unlink(runners[i].rom_path) == -1)
perror("unlink rom_path failed");
{
int fd;
if ((fd = open(runners[i].rom_path, O_RDONLY)) != -1)
perror("unlink rom_path failed");
}
}
}
}