You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by gg...@apache.org on 2024/06/28 20:28:02 UTC

(commons-compress) branch master updated (d16fcbd88 -> e8881d2a5)

This is an automated email from the ASF dual-hosted git repository.

ggregory pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/commons-compress.git


    from d16fcbd88 Upgrade commons-io from 2.15.1 to 2.16.1 #513
     new d3ebdd8e5 Upgrade commons-io from 2.15.1 to 2.16.1 #513
     new e8881d2a5 Upgrade commons-io from 2.15.1 to 2.16.1 #513

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .../org/apache/commons/compress/archivers/tar/TarArchiveEntry.java     | 2 +-
 .../apache/commons/compress/archivers/tar/TarArchiveOutputStream.java  | 3 ++-
 2 files changed, 3 insertions(+), 2 deletions(-)


(commons-compress) 02/02: Upgrade commons-io from 2.15.1 to 2.16.1 #513

Posted by gg...@apache.org.
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

commit e8881d2a5ca32f130428e6f27e3ccc5cb6798ce1
Author: Gary Gregory <ga...@gmail.com>
AuthorDate: Fri Jun 28 16:27:13 2024 -0400

    Upgrade commons-io from 2.15.1 to 2.16.1 #513
    
    - Migrate to non-deprecated code
    - Thanks to madrob Mike Drob and PR 513
    - https://github.com/apache/commons-compress/pull/513/files
---
 .../apache/commons/compress/archivers/tar/TarArchiveOutputStream.java  | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/main/java/org/apache/commons/compress/archivers/tar/TarArchiveOutputStream.java b/src/main/java/org/apache/commons/compress/archivers/tar/TarArchiveOutputStream.java
index 54de7b270..492bdb4ea 100644
--- a/src/main/java/org/apache/commons/compress/archivers/tar/TarArchiveOutputStream.java
+++ b/src/main/java/org/apache/commons/compress/archivers/tar/TarArchiveOutputStream.java
@@ -41,6 +41,7 @@ import org.apache.commons.compress.archivers.zip.ZipEncodingHelper;
 import org.apache.commons.compress.utils.FixedLengthBlockOutputStream;
 import org.apache.commons.compress.utils.TimeUtils;
 import org.apache.commons.io.Charsets;
+import org.apache.commons.io.file.attribute.FileTimes;
 import org.apache.commons.io.output.CountingOutputStream;
 import org.apache.commons.lang3.ArrayFill;
 
@@ -645,7 +646,7 @@ public class TarArchiveOutputStream extends ArchiveOutputStream<TarArchiveEntry>
         if (fromModTimeSeconds < 0 || fromModTimeSeconds > TarConstants.MAXSIZE) {
             fromModTimeSeconds = 0;
         }
-        to.setLastModifiedTime(TimeUtils.unixTimeToFileTime(fromModTimeSeconds));
+        to.setLastModifiedTime(FileTimes.fromUnixTime(fromModTimeSeconds));
     }
 
     /**


(commons-compress) 01/02: Upgrade commons-io from 2.15.1 to 2.16.1 #513

Posted by gg...@apache.org.
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

commit d3ebdd8e5eca211eb34f7ad705eec013ca5484bd
Author: Mike Drob <md...@apache.org>
AuthorDate: Fri Jun 28 16:26:38 2024 -0400

    Upgrade commons-io from 2.15.1 to 2.16.1 #513
    
    - Migrate to non-deprecated code
    - Thanks to madrob Mike Drob and PR 513
    - https://github.com/apache/commons-compress/pull/513/files
---
 .../java/org/apache/commons/compress/archivers/tar/TarArchiveEntry.java | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/main/java/org/apache/commons/compress/archivers/tar/TarArchiveEntry.java b/src/main/java/org/apache/commons/compress/archivers/tar/TarArchiveEntry.java
index b3f577996..e372b12e6 100644
--- a/src/main/java/org/apache/commons/compress/archivers/tar/TarArchiveEntry.java
+++ b/src/main/java/org/apache/commons/compress/archivers/tar/TarArchiveEntry.java
@@ -1479,7 +1479,7 @@ public class TarArchiveEntry implements ArchiveEntry, TarConstants, EntryStreamO
             throw new IOException("broken archive, entry with negative size");
         }
         offset += SIZELEN;
-        mTime = TimeUtils.unixTimeToFileTime(parseOctalOrBinary(header, offset, MODTIMELEN, lenient));
+        mTime = FileTimes.fromUnixTime(parseOctalOrBinary(header, offset, MODTIMELEN, lenient));
         offset += MODTIMELEN;
         checkSumOK = TarUtils.verifyCheckSum(header);
         offset += CHKSUMLEN;