Bug 18043 - untar should recognize non-tar files instead of expanding them to garbage
Summary: untar should recognize non-tar files instead of expanding them to garbage
Status: NEW
Alias: None
Product: Ant
Classification: Unclassified
Component: Core tasks (show other bugs)
Version: 1.5.1
Hardware: PC Linux
: P3 enhancement (vote)
Target Milestone: ---
Assignee: Ant Notifications List
URL: http://xml.apache.org/dist/xerces-j/X...
Keywords:
Depends on:
Blocks:
 
Reported: 2003-03-16 20:40 UTC by Justin Sher
Modified: 2008-11-24 03:57 UTC (History)
0 users



Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Justin Sher 2003-03-16 20:40:36 UTC
There must be a bug in the tar implementation because when I try to untar the
Xerces file ant hangs and starts producing huge files whose names and contents
appear to be a bunch of random data.  I untarred Xerces using redhat 8.0 tar and
retarred it and the files are slightly different sizes and it still generates
all kinds of random files.  Perhaps a bug reading the directory information?

This is the md5 hash of the offending Xerces file.

a203579b9b49b74f759717f388c4bbfa 



jdori.archive=${tools.dir}/jdori-1_0-fcs-src-04_Mar_2002.zip
tjdo.archive=${tools.dir}/TJDO_2_0_beta2.zip
xerces.archive=${tools.dir}Xerces-J-bin.2.3.0.tar.gz

<target name="install-jdo" depends="init">
	<unzip src="${tjdo.archive}" dest="${lib.java.dir}"/>
	<unzip src="${jdori.archive}" dest="${temp.dir}/jdori"/>
	<copy file="${temp.dir}/jdori/src/jdo.jar" todir="${lib.java.dir}"/>
	<copy file="${temp.dir}/jdori/src/jdori.jar" todir="${lib.java.dir}"/>
	<move file="${lib.java.dir}/tjdo/lib/tjdo.jar" todir="${lib.java.dir}"/>
	<untar src="${xerces.archive}" dest="${lib.java.dir}" />
</target>
Comment 1 Justin Sher 2003-03-16 20:41:12 UTC
The file that is causing the problem is specified in the URL for this bug
Comment 2 Justin Sher 2003-03-16 20:43:46 UTC
oh duh :) ! It's gzipped, still there should be some better error handling here.