bug-tar
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug-tar] abort in 1.15.1 when using -rz


From: Eric Blake
Subject: [Bug-tar] abort in 1.15.1 when using -rz
Date: Wed, 21 Dec 2005 06:01:18 -0700
User-agent: Mozilla Thunderbird 1.0.2 (Windows/20050317)

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

This was reported on the cygwin mailing list:

$ touch file1 file2
$ tar -vczf exist.tar.gz file1
$ tar -vrzf exist.tar.gz file2
Aborted (core dumped)

(gdb) bt
#0  0x0042ea80 in abort ()
#1  0x004018cd in open_archive (wanted_access=ACCESS_UPDATE)
    at ../../src/buffer.c:429
#2  0x004193d3 in update_archive () at ../../src/update.c:112
#3  0x00418f6f in main (argc=4, argv=0x4f2610) at ../../src/tar.c:1668
(gdb) l open_archive
...
414       if (use_compress_program_option)
415         {
416           switch (wanted_access)
417             {
418             case ACCESS_READ:
419               child_pid = sys_child_open_for_uncompress ();
420               read_full_records = reading_from_pipe = true;
421               record_end = record_start; /* set up for 1st record = # 0 */
422               break;
423
424             case ACCESS_WRITE:
425               child_pid = sys_child_open_for_compress ();
426               break;
427
428             case ACCESS_UPDATE:
429               abort (); /* Should not happen */
430               break;
431             }
432
...

I note that open_archive in CVS head still has the same code, but that tar
avoids the abort by erroring out earlier with a complaint that you "Cannot
update compressed archives".  I don't see any mention of this change in
NEWS, and couldn't find it with a quick search of the ChangeLog.  Any
chance that you can help me find the patch that fixed this, so I can
backport it to the 1.15.1 tar in the cygwin distribution? (or better yet,
is 1.15.2 coming out soon?)  Also, it seems like a strange limitation that
you can't append files into a compressed archive.

- --
Life is short - so eat dessert first!

Eric Blake             address@hidden
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (Cygwin)
Comment: Public key at home.comcast.net/~ericblake/eblake.gpg
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

iD8DBQFDqVIe84KuGfSFAYARAkeNAKDTmWTol9mpxf63itno0lZm9Nk9TQCgwZis
Omb2UB5i/rBbgKRCHXzRcbw=
=oXLW
-----END PGP SIGNATURE-----




reply via email to

[Prev in Thread] Current Thread [Next in Thread]