archive/iso9660: use IsSpecialFilename()

This commit is contained in:
Max Kellermann 2020-03-07 09:15:54 +01:00
parent b7ce452308
commit 73a1f078a6
1 changed files with 2 additions and 1 deletions

View File

@ -93,7 +93,8 @@ Iso9660ArchiveFile::Visit(char *path, size_t length, size_t capacity,
auto *statbuf = (iso9660_stat_t *)
_cdio_list_node_data(entnode);
const char *filename = statbuf->filename;
if (strcmp(filename, ".") == 0 || strcmp(filename, "..") == 0)
if (PathTraitsUTF8::IsSpecialFilename(filename))
/* skip special names like "." and ".." */
continue;
size_t filename_length = strlen(filename);