This is an automated email from the ASF dual-hosted git repository. ggregory pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/commons-compress.git
The following commit(s) were added to refs/heads/master by this push: new 3819519 Use new API ArchiveOutputStream.createArchiveEntry(Path, String, LinkOption...). 3819519 is described below commit 38195196f73d9db9335b0e46c1ca0bed1f2c40e8 Author: Gary Gregory <garydgreg...@gmail.com> AuthorDate: Sat Aug 8 16:22:22 2020 -0400 Use new API ArchiveOutputStream.createArchiveEntry(Path, String, LinkOption...). --- .../java/org/apache/commons/compress/archivers/examples/Archiver.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/org/apache/commons/compress/archivers/examples/Archiver.java b/src/main/java/org/apache/commons/compress/archivers/examples/Archiver.java index 3b10009..3bdb55d 100644 --- a/src/main/java/org/apache/commons/compress/archivers/examples/Archiver.java +++ b/src/main/java/org/apache/commons/compress/archivers/examples/Archiver.java @@ -71,7 +71,7 @@ public class Archiver { Objects.requireNonNull(attrs); final String name = directory.relativize(path).toString().replace('\\', '/'); if (!name.isEmpty()) { - final ArchiveEntry archiveEntry = target.createArchiveEntry(path.toFile(), + final ArchiveEntry archiveEntry = target.createArchiveEntry(path, isFile || name.endsWith("/") ? name : name + "/"); target.putArchiveEntry(archiveEntry); if (isFile) {