Skip to content

Commit

Permalink
[Fix] Ignore non-directory root path entry in an archive.
Browse files Browse the repository at this point in the history
  • Loading branch information
zhanghai committed Sep 10, 2023
1 parent f80790d commit 4ed9fb5
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,11 @@ object ArchiveReader {
// Don't allow a path to become the root path only after normalization.
continue
}
} else {
if (!entry.isDirectory) {
// Ignore a root path that's not a directory
continue
}
}
entries.getOrPut(path) { entry }
}
Expand Down

0 comments on commit 4ed9fb5

Please sign in to comment.