Return-Path: Delivered-To: apmail-ant-user-archive@www.apache.org Received: (qmail 53868 invoked from network); 23 Jan 2006 02:41:44 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 23 Jan 2006 02:41:44 -0000 Received: (qmail 82098 invoked by uid 500); 23 Jan 2006 02:41:40 -0000 Delivered-To: apmail-ant-user-archive@ant.apache.org Received: (qmail 82024 invoked by uid 500); 23 Jan 2006 02:41:40 -0000 Mailing-List: contact user-help@ant.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Help: List-Post: List-Id: "Ant Users List" Reply-To: "Ant Users List" Delivered-To: mailing list user@ant.apache.org Received: (qmail 78857 invoked by uid 99); 23 Jan 2006 02:35:55 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests=HTML_MESSAGE X-Spam-Check-By: apache.org Received-SPF: pass (asf.osuosl.org: local policy) Message-ID: <000f01c61fc5$abc1eff0$6400a8c0@scaggslap> From: "Bob Scaggs" To: Subject: Re: "java.io.IOException: Negative seek offset" while expanding .tar file Date: Sun, 22 Jan 2006 21:35:27 -0500 MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_NextPart_000_000C_01C61F9B.C2A40980" X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2800.1437 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1441 X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N ------=_NextPart_000_000C_01C61F9B.C2A40980 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable oops typo in my test code. Same problem with corrected code: =20 This is file1 This is file2 This is file3 ----- Original Message -----=20 From: Bob Scaggs=20 To: user@ant.apache.org=20 Sent: Sunday, January 22, 2006 1:33 PM Subject: "java.io.IOException: Negative seek offset" while expanding = .tar file I am getting an error when I use the unzip task to expand a tar file = created using the tar task. Below is a sample of the code I am executing as well as the error I am = recieving. Can anyone help with this? listing of build.xml: This is = file1 This is = file2 This is = file3 Result of "ant -verbose" using the above build file: C:\test>ant -verbose Apache Ant version 1.6.2 compiled on July 16 2004 Buildfile: build.xml Detected Java version: 1.4 in: = C:\Progra~1\IBM\Rational\SDP\6.0\runtimes\base_v6 \_jvm\jre Detected OS: Windows XP parsing buildfile C:\test\build.xml with URI =3D = file:///C:/test/build.xml Project base dir set to: C:\test Build sequence for target `unTar' is [prepareDirs, buildTestFiles, = makeTar, unTa r] Complete build sequence is [prepareDirs, buildTestFiles, makeTar, = unTar, ] prepareDirs: [mkdir] Created dir: C:\test\tar [mkdir] Created dir: C:\test\buildTemp [mkdir] Created dir: C:\test\buildTemp\TestFilesDir [mkdir] Created dir: C:\test\expandedFiles buildTestFiles: makeTar: [tar] added as C:/test/tar/test.tar doesn't exist. [tar] TestFilesDir added as C:/test/tar/test.tar doesn't exist. [tar] TestFilesDir\file1.txt added as C:/test/tar/test.tar = doesn't exist. [tar] TestFilesDir\file2.txt added as C:/test/tar/test.tar = doesn't exist. [tar] TestFilesDir\file3.txt added as C:/test/tar/test.tar = doesn't exist. [tar] Building tar: C:\test\tar\test.tar unTar: Property ${TARdistributionDir} has not been set [unzip] Expanding: C:\test\tar\test.tar into = C:\test\${TARdistributionDir} BUILD FAILED C:\test\build.xml:10: Error while expanding C:\test\tar\test.tar at org.apache.tools.ant.taskdefs.Expand.expandFile(Expand.java:128) at org.apache.tools.ant.taskdefs.Expand.execute(Expand.java:92) at = org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:275) at org.apache.tools.ant.Task.perform(Task.java:364) at org.apache.tools.ant.Target.execute(Target.java:341) at org.apache.tools.ant.Target.performTasks(Target.java:369) at org.apache.tools.ant.Project.executeTarget(Project.java:1214) at org.apache.tools.ant.Project.executeTargets(Project.java:1062) at org.apache.tools.ant.Main.runBuild(Main.java:673) at org.apache.tools.ant.Main.startAnt(Main.java:188) at org.apache.tools.ant.launch.Launcher.run(Launcher.java:196) at org.apache.tools.ant.launch.Launcher.main(Launcher.java:55) Caused by: java.io.IOException: Negative seek offset at java.io.RandomAccessFile.seek(Native Method) at = org.apache.tools.zip.ZipFile.positionAtCentralDirectory(ZipFile.java( Compiled Code)) at = org.apache.tools.zip.ZipFile.populateFromCentralDirectory(ZipFile.jav a:235) at org.apache.tools.zip.ZipFile.(ZipFile.java:142) at org.apache.tools.ant.taskdefs.Expand.expandFile(Expand.java:117) ... 11 more --- Nested Exception --- java.io.IOException: Negative seek offset at java.io.RandomAccessFile.seek(Native Method) at = org.apache.tools.zip.ZipFile.positionAtCentralDirectory(ZipFile.java( Compiled Code)) at = org.apache.tools.zip.ZipFile.populateFromCentralDirectory(ZipFile.jav a:235) at org.apache.tools.zip.ZipFile.(ZipFile.java:142) at org.apache.tools.ant.taskdefs.Expand.expandFile(Expand.java:117) at org.apache.tools.ant.taskdefs.Expand.execute(Expand.java:92) at = org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:275) at org.apache.tools.ant.Task.perform(Task.java:364) at org.apache.tools.ant.Target.execute(Target.java:341) at org.apache.tools.ant.Target.performTasks(Target.java:369) at org.apache.tools.ant.Project.executeTarget(Project.java:1214) at org.apache.tools.ant.Project.executeTargets(Project.java:1062) at org.apache.tools.ant.Main.runBuild(Main.java:673) at org.apache.tools.ant.Main.startAnt(Main.java:188) at org.apache.tools.ant.launch.Launcher.run(Launcher.java:196) at org.apache.tools.ant.launch.Launcher.main(Launcher.java:55) Total time: 1 second ------=_NextPart_000_000C_01C61F9B.C2A40980--