You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by "chen (Jira)" <ji...@apache.org> on 2021/09/27 01:13:00 UTC

[jira] [Updated] (COMPRESS-589) 1.21 throws a 'java.io.IOException: Truncated TAR archive' exception while 1.20 not

     [ https://issues.apache.org/jira/browse/COMPRESS-589?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

chen updated COMPRESS-589:
--------------------------
    Description: 
the bug happens when I use the TarArchiveInputStream to read bytes from the current tar archive entry.

first of all, we ran into this issue on an *{color:#ff0000}Android device{color}*

the trace shows as below
{code:java}
08-27 14:39:18.657 10633 10963 W System.err: java.io.IOException: Truncated TAR archive
08-27 14:39:18.657 10633 10963 W System.err: java.io.IOException: Truncated TAR archive
08-27 14:39:18.657 10633 10963 W System.err: at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.getActuallySkipped(TarArchiveInputStream.java:478)
08-27 14:39:18.657 10633 10963 W System.err: at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.skipRecordPadding(TarArchiveInputStream.java:455)
08-27 14:39:18.657 10633 10963 W System.err: at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.getNextTarEntry(TarArchiveInputStream.java:367)
{code}
but when i downgrade to 1.20, the exception will not show again, so I think it is a bug in the new version 

 

 

  was:
the bug happens when I use the TarArchiveInputStream to read bytes from the current tar archive entry.

the trace shows as below
{code:java}
08-27 14:39:18.657 10633 10963 W System.err: java.io.IOException: Truncated TAR archive
08-27 14:39:18.657 10633 10963 W System.err: java.io.IOException: Truncated TAR archive
08-27 14:39:18.657 10633 10963 W System.err: at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.getActuallySkipped(TarArchiveInputStream.java:478)
08-27 14:39:18.657 10633 10963 W System.err: at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.skipRecordPadding(TarArchiveInputStream.java:455)
08-27 14:39:18.657 10633 10963 W System.err: at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.getNextTarEntry(TarArchiveInputStream.java:367)
{code}
but when i downgrade to 1.20, the exception will not show again, so I think it is a bug in the new version 

 

 


> 1.21 throws a 'java.io.IOException: Truncated TAR archive' exception while 1.20 not
> -----------------------------------------------------------------------------------
>
>                 Key: COMPRESS-589
>                 URL: https://issues.apache.org/jira/browse/COMPRESS-589
>             Project: Commons Compress
>          Issue Type: Bug
>    Affects Versions: 1.21
>            Reporter: chen
>            Priority: Major
>
> the bug happens when I use the TarArchiveInputStream to read bytes from the current tar archive entry.
> first of all, we ran into this issue on an *{color:#ff0000}Android device{color}*
> the trace shows as below
> {code:java}
> 08-27 14:39:18.657 10633 10963 W System.err: java.io.IOException: Truncated TAR archive
> 08-27 14:39:18.657 10633 10963 W System.err: java.io.IOException: Truncated TAR archive
> 08-27 14:39:18.657 10633 10963 W System.err: at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.getActuallySkipped(TarArchiveInputStream.java:478)
> 08-27 14:39:18.657 10633 10963 W System.err: at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.skipRecordPadding(TarArchiveInputStream.java:455)
> 08-27 14:39:18.657 10633 10963 W System.err: at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.getNextTarEntry(TarArchiveInputStream.java:367)
> {code}
> but when i downgrade to 1.20, the exception will not show again, so I think it is a bug in the new version 
>  
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)