]> git.ipfire.org Git - thirdparty/libarchive.git/log
thirdparty/libarchive.git
15 years agoIssue 113: Include an error message when the size overflows.
Tim Kientzle [Fri, 12 Nov 2010 04:47:46 +0000 (23:47 -0500)] 
Issue 113:  Include an error message when the size overflows.

SVN-Revision: 2784

15 years agoIssue 94: When writing into an fd that's not seekable (e.g., a pipe),
Tim Kientzle [Wed, 10 Nov 2010 07:05:47 +0000 (02:05 -0500)] 
Issue 94: When writing into an fd that's not seekable (e.g., a pipe),
we have to fill in zero holes for sparse files.

SVN-Revision: 2783

15 years agoIssue 113: When writing headers, return ARCHIVE_FAILED
Tim Kientzle [Wed, 10 Nov 2010 05:59:05 +0000 (00:59 -0500)] 
Issue 113:  When writing headers, return ARCHIVE_FAILED
on various problems:
  * Missing name
  * Missing size (except for hardlinks)
  * Missing filetype
  * Size too large for format

SVN-Revision: 2782

15 years agoIf we see junk when we're expecting a 'PK' signature
Tim Kientzle [Sun, 7 Nov 2010 02:14:21 +0000 (22:14 -0400)] 
If we see junk when we're expecting a 'PK' signature
block, scan forward to see if we can find a suitable
signature.

This is necessary to read archives that have been modified
by some Zip utilities that update entries in-place without
compacting the entire archive.

Of course, this would be very natural if libarchive
used the Central directory.  But even when libarchive
does support the Central directory, this kind of logic
will still be useful for reading Zip archives in streaming
mode.

SVN-Revision: 2781

15 years agoDeclare a function that was omitted.
Tim Kientzle [Wed, 3 Nov 2010 05:50:42 +0000 (01:50 -0400)] 
Declare a function that was omitted.

SVN-Revision: 2779

15 years agoReturn NULL if there is no error message.
Tim Kientzle [Sun, 31 Oct 2010 06:35:10 +0000 (02:35 -0400)] 
Return NULL if there is no error message.
In particular, we should start filling in assertions in lots
of tests to verify that textual error messages are getting
generated on errors.

SVN-Revision: 2777

15 years agoA test for r2769: Truncated compressed inputs should
Tim Kientzle [Sun, 31 Oct 2010 06:34:22 +0000 (02:34 -0400)] 
A test for r2769:  Truncated compressed inputs should
fail cleanly and include a text error message.

SVN-Revision: 2776

15 years agoRemove an outdated comment.
Tim Kientzle [Sun, 31 Oct 2010 06:33:20 +0000 (02:33 -0400)] 
Remove an outdated comment.

SVN-Revision: 2775

15 years agoAllow failure(NULL) to clear the failure detail message.
Tim Kientzle [Sun, 31 Oct 2010 06:26:15 +0000 (02:26 -0400)] 
Allow failure(NULL) to clear the failure detail message.

SVN-Revision: 2774

15 years ago__archive_write_filter returns a status, not a count of bytes written.
Tim Kientzle [Sun, 31 Oct 2010 06:24:18 +0000 (02:24 -0400)] 
__archive_write_filter returns a status, not a count of bytes written.
Correct the bzip2 and compress writers.

SVN-Revision: 2773

15 years agoReconcile the test harnesses across libarchive, tar, and cpio.
Tim Kientzle [Sun, 31 Oct 2010 04:44:03 +0000 (00:44 -0400)] 
Reconcile the test harnesses across libarchive, tar, and cpio.
Remove almost all of the varargs capabilities from the various
assertion helpers, since they complicate the code and are
hardly ever used.

SVN-Revision: 2772

15 years agosvn:ignore Mac OS .dylib files
Tim Kientzle [Sun, 31 Oct 2010 03:41:02 +0000 (23:41 -0400)] 
svn:ignore Mac OS .dylib files

SVN-Revision: 2771

15 years agoInclude an actual text error message if the gzip, bzip2, xz, lzma, or
Tim Kientzle [Sun, 31 Oct 2010 03:28:15 +0000 (23:28 -0400)] 
Include an actual text error message if the gzip, bzip2, xz, lzma, or
lzip input is truncated.

SVN-Revision: 2769

15 years agoHandle umask a little more carefully: Instead of setting umask to
Tim Kientzle [Sat, 30 Oct 2010 07:38:53 +0000 (03:38 -0400)] 
Handle umask a little more carefully:  Instead of setting umask to
zero, then restoring a file, then restoring umask, just query
the umask and adjust the file restore operations to account for it.

Go ahead and query the umask at new() time as well.
This opens the possibility of removing the umask query from
write_disk_header if you want to make libarchive behave more
nicely with threads.

SVN-Revision: 2768

15 years agoAfter removing support for writing SCHILY.dev/ino/nlink keyword,
Tim Kientzle [Tue, 26 Oct 2010 05:28:47 +0000 (01:28 -0400)] 
After removing support for writing SCHILY.dev/ino/nlink keyword,
I didn't update all of the tests.

SVN-Revision: 2765

15 years agoIssue 112: Use int64_t for tracking total size of entry
Tim Kientzle [Tue, 26 Oct 2010 05:18:26 +0000 (01:18 -0400)] 
Issue 112: Use int64_t for tracking total size of entry
when parsing off GNU tar sparse file information.

SVN-Revision: 2764

15 years agoAccept both '!' and '^' for a negated character class.
Tim Kientzle [Wed, 6 Oct 2010 04:19:58 +0000 (00:19 -0400)] 
Accept both '!' and '^' for a negated character class.

SVN-Revision: 2748

15 years agofix a bug introduced in the last set of cleanups to this file; if setting the unconsu...
Brian Harring [Mon, 27 Sep 2010 15:42:07 +0000 (11:42 -0400)] 
fix a bug introduced in the last set of cleanups to this file; if setting the unconsumed, don't invoke consume ourselves (this fixes the readahead/consume in this case)

SVN-Revision: 2741

15 years agofix a read_ahead/consume pairing that was missed in the cleanup
Brian Harring [Mon, 27 Sep 2010 15:40:00 +0000 (11:40 -0400)] 
fix a read_ahead/consume pairing that was missed in the cleanup

SVN-Revision: 2740

15 years agointercept dumb requests, and return immediately
Brian Harring [Mon, 27 Sep 2010 15:37:49 +0000 (11:37 -0400)] 
intercept dumb requests, and return immediately

SVN-Revision: 2739

15 years agofix more read_ahead/consume pairings to ensure that when a consume is invoked, that...
Brian Harring [Mon, 27 Sep 2010 15:28:19 +0000 (11:28 -0400)] 
fix more read_ahead/consume pairings to ensure that when a consume is invoked, that data is no longer accessed

SVN-Revision: 2738

15 years agoupdate iso archive for proper read_(ahead|consume) pairing... that's the last of...
Brian Harring [Sat, 25 Sep 2010 07:03:50 +0000 (03:03 -0400)] 
update iso archive for proper read_(ahead|consume) pairing... that's the last of 'em.

SVN-Revision: 2701

15 years agoupdate zip for proper read_(ahead|consume).
Brian Harring [Sat, 25 Sep 2010 06:46:42 +0000 (02:46 -0400)] 
update zip for proper read_(ahead|consume).

SVN-Revision: 2700

15 years agocleanup xar's readahead/consume pairing... pretty clean actually.
Brian Harring [Sat, 25 Sep 2010 06:12:39 +0000 (02:12 -0400)] 
cleanup xar's readahead/consume pairing... pretty clean actually.

SVN-Revision: 2699

15 years agofinish conversion over to tar_flush_unconsumed, and converting adhoc readahead/consum...
Brian Harring [Sat, 25 Sep 2010 05:43:07 +0000 (01:43 -0400)] 
finish conversion over to tar_flush_unconsumed, and converting adhoc readahead/consume pairing.  Haven't been able to pinpoint why test_read_large, test_read_truncated, and test_read_data_large fail when poisoning is enabled- either the readahead/consume pairing is still off slightly, or (what I suspect) there is a dangling ptr that just happens to work currently.  Will root this one out under libtransform where I can more easily make the actual space no longer valid (literal free'ing), hopefully smoking it out via a segfault.

SVN-Revision: 2698

15 years agomore work to pair tar's readahead/consume; this still isn't perfect (the disabled...
Brian Harring [Sat, 25 Sep 2010 04:36:27 +0000 (00:36 -0400)] 
more work to pair tar's readahead/consume; this still isn't perfect (the disabled poison code w/in tar_flush_unconsumed confirms this), although pretty close.

SVN-Revision: 2697

15 years agoinitial cleanup of tar readahead/consume pairing; not finished (read_header is a...
Brian Harring [Fri, 24 Sep 2010 07:44:52 +0000 (03:44 -0400)] 
initial cleanup of tar readahead/consume pairing; not finished (read_header is a doozie)

SVN-Revision: 2696

15 years agoupdate raw w/ proper read_ahead/consume pairing
Brian Harring [Fri, 24 Sep 2010 05:27:00 +0000 (01:27 -0400)] 
update raw w/ proper read_ahead/consume pairing

SVN-Revision: 2695

15 years agoadd a format level data skip to cpio
Brian Harring [Thu, 23 Sep 2010 13:08:03 +0000 (09:08 -0400)] 
add a format level data skip to cpio

SVN-Revision: 2694

15 years agoconsume only when the read_ahead data is no longer in use...
Brian Harring [Thu, 23 Sep 2010 13:00:50 +0000 (09:00 -0400)] 
consume only when the read_ahead data is no longer in use...

SVN-Revision: 2693

15 years agohopefully the last ar mod needed; same thing as the last set of commits, do not mark...
Brian Harring [Thu, 23 Sep 2010 11:52:21 +0000 (07:52 -0400)] 
hopefully the last ar mod needed; same thing as the last set of commits, do not mark data you're actively using as consumed till it's consumed

SVN-Revision: 2692

15 years agoreplace an adhoc consume/skip invocation with a proper skip/consume invocation (prima...
Brian Harring [Thu, 23 Sep 2010 11:40:18 +0000 (07:40 -0400)] 
replace an adhoc consume/skip invocation with a proper skip/consume invocation (primarily relevant since the underlaying transforms/source may be able to shift to an lseek; unlikely, but it simplifies the code a bit).  As for updating padding when the seek is less than what was requested, this is being done purely to keep existing behaviour- the ARCHIVE_FATAL return should make this a noop, but being safe.

SVN-Revision: 2691

15 years agominor tweak; trust the unconsumed value returned back rather than just assuming it...
Brian Harring [Thu, 23 Sep 2010 11:27:06 +0000 (07:27 -0400)] 
minor tweak; trust the unconsumed value returned back rather than just assuming it's always 60.  This is primarily a robustness change

SVN-Revision: 2690

15 years agonot hugely happy with the implementation (specifically unconsumed passing), but rewor...
Brian Harring [Thu, 23 Sep 2010 11:26:11 +0000 (07:26 -0400)] 
not hugely happy with the implementation (specifically unconsumed passing), but rework the header reading to properly pair it's read_ahead/consume usage

SVN-Revision: 2689

15 years agofix another mispairing of read_ahead/consume
Brian Harring [Thu, 23 Sep 2010 11:06:59 +0000 (07:06 -0400)] 
fix another mispairing of read_ahead/consume

SVN-Revision: 2688

15 years agocorrect a mismatch- you tell libarchive something is consumed only after you've actua...
Brian Harring [Thu, 23 Sep 2010 10:21:09 +0000 (06:21 -0400)] 
correct a mismatch- you tell libarchive something is consumed only after you've actually consumed it.  Once you've consumed a read_ahead block, the data it points to is volatile.  Mainline trunk currently currently wouldn't cause issues with this usage, but the usage violates the api contract (and will have issues under libtransform) so fixing it.

SVN-Revision: 2687

15 years agofix an overlapping memcpy identified by valgrind; use memove instead
Brian Harring [Wed, 22 Sep 2010 14:32:46 +0000 (10:32 -0400)] 
fix an overlapping memcpy identified by valgrind; use memove instead

SVN-Revision: 2684

15 years agofix out of bounds access; confirm the size, than do the access.
Brian Harring [Wed, 22 Sep 2010 03:41:19 +0000 (23:41 -0400)] 
fix out of bounds access; confirm the size, than do the access.

SVN-Revision: 2677

15 years agofix tcp.sh to work (looks like upon importation it picked up some address scrubbing...
Brian Harring [Wed, 1 Sep 2010 12:25:23 +0000 (08:25 -0400)] 
fix tcp.sh to work (looks like upon importation it picked up some address scrubbing crap from gmail/websites).  tweak the logic slightly also to just process available tar implementaitons for testing

SVN-Revision: 2608

15 years agoRemove the SCHILY dev/ino/nlink attributes, since noone seems to
Tim Kientzle [Sun, 22 Aug 2010 20:33:41 +0000 (16:33 -0400)] 
Remove the SCHILY dev/ino/nlink attributes, since noone seems to
be actually using them and they generate a lot of complaints.

SVN-Revision: 2563

15 years agoWhen -R is specified, make sure to clear the uname/gname
Tim Kientzle [Sun, 15 Aug 2010 04:11:25 +0000 (00:11 -0400)] 
When -R is specified, make sure to clear the uname/gname
fields.  Add a TODO here for the -R parser to return
usable uname/gname text (only useful for tar output,
so not a huge priority right now).

SVN-Revision: 2554

15 years agoUpdate config_freebsd.h
Tim Kientzle [Tue, 10 Aug 2010 05:56:44 +0000 (01:56 -0400)] 
Update config_freebsd.h

SVN-Revision: 2553

15 years agoFix a signed mismatch on 64-bit architectures.
Tim Kientzle [Tue, 10 Aug 2010 05:56:19 +0000 (01:56 -0400)] 
Fix a signed mismatch on 64-bit architectures.

SVN-Revision: 2552

15 years agoCorrect some signed/unsigned mismatches on 64-bit platforms.
Tim Kientzle [Tue, 10 Aug 2010 05:55:34 +0000 (01:55 -0400)] 
Correct some signed/unsigned mismatches on 64-bit platforms.

SVN-Revision: 2551

15 years agoRemove unused STDIN_FILNO, STDOUT_FILENO, STDERR_FILENO definitions.
Tim Kientzle [Tue, 10 Aug 2010 05:31:14 +0000 (01:31 -0400)] 
Remove unused STDIN_FILNO, STDOUT_FILENO, STDERR_FILENO definitions.

SVN-Revision: 2550

15 years agoRemove a couple of unused arguments from internal functions.
Tim Kientzle [Sun, 8 Aug 2010 22:56:40 +0000 (18:56 -0400)] 
Remove a couple of unused arguments from internal functions.

SVN-Revision: 2549

15 years agoPreserve const when casting.
Tim Kientzle [Sun, 8 Aug 2010 22:43:31 +0000 (18:43 -0400)] 
Preserve const when casting.

SVN-Revision: 2548

15 years agombstowcs returns size_t, so store the result in a size_t.
Tim Kientzle [Sun, 8 Aug 2010 22:42:33 +0000 (18:42 -0400)] 
mbstowcs returns size_t, so store the result in a size_t.

SVN-Revision: 2547

15 years agoUse the same type for both branches of the ternary here.
Tim Kientzle [Sun, 8 Aug 2010 22:41:56 +0000 (18:41 -0400)] 
Use the same type for both branches of the ternary here.

SVN-Revision: 2546

15 years agoUnused variable.
Tim Kientzle [Sun, 8 Aug 2010 22:37:27 +0000 (18:37 -0400)] 
Unused variable.

SVN-Revision: 2545

15 years agoDisable sparse file support on Linux.
Tim Kientzle [Sun, 1 Aug 2010 06:16:36 +0000 (02:16 -0400)] 
Disable sparse file support on Linux.
The setup_sparse() function needs to be rewritten to properly
merge extent information into a useful file map.

SVN-Revision: 2544

15 years agoAccept and ignore multiple PVDs.
Tim Kientzle [Sat, 31 Jul 2010 17:14:11 +0000 (13:14 -0400)] 
Accept and ignore multiple PVDs.

Thanks to: Aaron W Hsu for sharing some ISO images with multiple PVDs
  that were previously rejected.

SVN-Revision: 2543

15 years agoAdd the new libarchive/test/test_open_failure.c to the
Tim Kientzle [Sat, 31 Jul 2010 16:40:07 +0000 (12:40 -0400)] 
Add the new libarchive/test/test_open_failure.c to the
autoconf-based build system.

SVN-Revision: 2542

15 years agoNew test: Verify that failures of the client opener
Tim Kientzle [Sun, 25 Jul 2010 01:17:34 +0000 (21:17 -0400)] 
New test:  Verify that failures of the client opener
or initial read produce an immediate close
and don't cause any problems when freeing the archive.

SVN-Revision: 2541

15 years agoInstead of trying a read-ahead after each filter stage,
Tim Kientzle [Sun, 25 Jul 2010 01:16:30 +0000 (21:16 -0400)] 
Instead of trying a read-ahead after each filter stage,
just do it once after the full pipeline is built.
In particular, this catches errors on uncompressed
input at open time.  Also, if any filter stage fails
to initialize, clean up the entire pipeline
immediately.

SVN-Revision: 2540

15 years agoIf opening the filter pipeline fails, immediately
Tim Kientzle [Sun, 25 Jul 2010 01:11:34 +0000 (21:11 -0400)] 
If opening the filter pipeline fails, immediately
close the pipeline and return with an error without
initializing the format writer.  Ensure that close requests
propagate up the pipeline even if a particular
stage hasn't registered a closer.

In particular, this fixes a crash that occurs when
write openers would fail but the format would get
initialized anyway.  At close time, formats such
as tar perform a write that would crash because the
pipeline wasn't fully initialized.  With this
change, the format never gets initialized in
this case so it doesn't need to be cleaned up.

SVN-Revision: 2539

15 years agoTreat ENOSYS as ENOTSUP for optional features to avoid fatal errors.
Andreas Henriksson [Tue, 20 Jul 2010 09:13:39 +0000 (05:13 -0400)] 
Treat ENOSYS as ENOTSUP for optional features to avoid fatal errors.

This fixes libarchive on (Debian GNU/Linux) HPPA,
where ENOSYS is returned for xattrs.

See http://code.google.com/p/libarchive/issues/detail?id=102
and original report at
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=588925#10

SVN-Revision: 2537

15 years agoAs reported by Aaron W Hsu, some ISO writers put a
Tim Kientzle [Mon, 19 Jul 2010 05:24:09 +0000 (01:24 -0400)] 
As reported by Aaron W Hsu, some ISO writers put a
Path Table starting at sector 18; the taster was rejecting
such archives (requiring that the path table start after
sector 18).

SVN-Revision: 2536

15 years agoVirtualize archive_read_next_header(). In particular, attempts to
Tim Kientzle [Sat, 17 Jul 2010 23:23:16 +0000 (19:23 -0400)] 
Virtualize archive_read_next_header().  In particular, attempts to
call this on a read_disk handle will fail immediately with a Null
pointer dereference instead of trying to run the archive_read
implementation, which fails with a much more inscrutable error.

SVN-Revision: 2535

15 years agoFix typo
Joerg Sonnenberger [Thu, 15 Jul 2010 15:00:37 +0000 (11:00 -0400)] 
Fix typo

SVN-Revision: 2534

16 years agoAs discussed on the libarchive-discuss mailing list,
Tim Kientzle [Tue, 13 Jul 2010 03:36:29 +0000 (23:36 -0400)] 
As discussed on the libarchive-discuss mailing list,
don't use any special declaration marker for GNU C on Windows.
The explicit dllimport marker hasn't been needed for many years
and removing it allows the same headers to be used for either a
static or dynamic library.

SVN-Revision: 2533

16 years agoOn Windows, use UNICODE version APIs to exceed the limitation of path length.
Michihiro NAKAJIMA [Fri, 9 Jul 2010 16:08:13 +0000 (12:08 -0400)] 
On Windows, use UNICODE version APIs to exceed the limitation of path length.

SVN-Revision: 2532

16 years agoOn Windows, use BY_HANDLE_FILE_INFORMAION directly to set up a archive_entry
Michihiro NAKAJIMA [Thu, 8 Jul 2010 15:59:50 +0000 (11:59 -0400)] 
On Windows, use BY_HANDLE_FILE_INFORMAION directly to set up a archive_entry
object instead of struct stat with archive_entry_copy_stat in
directory traversals.

SVN-Revision: 2529

16 years agoTrim \r from each line of archive_read_disk.c
Michihiro NAKAJIMA [Thu, 8 Jul 2010 14:00:49 +0000 (10:00 -0400)] 
Trim \r from each line of archive_read_disk.c

SVN-Revision: 2528

16 years agoDon't abuse typecasts, fix a build failure on FreeBSD 7.3.
Tim Kientzle [Thu, 8 Jul 2010 04:09:05 +0000 (00:09 -0400)] 
Don't abuse typecasts, fix a build failure on FreeBSD 7.3.

SVN-Revision: 2527

16 years agoRework minitar example to use archive_read_disk directory
Tim Kientzle [Sun, 4 Jul 2010 02:38:06 +0000 (22:38 -0400)] 
Rework minitar example to use archive_read_disk directory
traversal instead of a local copy of tree.c

SVN-Revision: 2526

16 years agoFor libarchive 3.0, use int64_t instead of uid_t, gid_t, ino_t.
Tim Kientzle [Sat, 3 Jul 2010 22:12:20 +0000 (18:12 -0400)] 
For libarchive 3.0, use int64_t instead of uid_t, gid_t, ino_t.

SVN-Revision: 2525

16 years agoFinish fixing the breakage from r2522: In particular, fcopyfile() seems
Tim Kientzle [Sat, 3 Jul 2010 03:56:02 +0000 (23:56 -0400)] 
Finish fixing the breakage from r2522:  In particular, fcopyfile() seems
broken so we can't use the more straightforward (and more secure)
fd-oriented approach here.

SVN-Revision: 2524

16 years agoFix a counting error in the Mac pathname editing.
Tim Kientzle [Sat, 3 Jul 2010 02:32:12 +0000 (22:32 -0400)] 
Fix a counting error in the Mac pathname editing.
Using memmove() here is efficient, but a bit touchy.
This fixes bsdtar_test_copy, which was broken in r2522.

SVN-Revision: 2523

16 years agoPush support for writing Mac attributes into tar archives
Tim Kientzle [Sat, 3 Jul 2010 01:44:49 +0000 (21:44 -0400)] 
Push support for writing Mac attributes into tar archives
out of tar and into libarchive.

In particular, this makes the Mac support available to
cpio and other clients; it's no longer specific to tar.

Note, though, that this also implies that Mac attribute
support is specific to the format writer.

SVN-Revision: 2522

16 years agoiso9660: disable trailing dot stripping code in joliet for now.
Andreas Henriksson [Fri, 2 Jul 2010 07:33:27 +0000 (03:33 -0400)] 
iso9660: disable trailing dot stripping code in joliet for now.

Haven't been able to figure out what makes this code not work.
Disable it for now with a comment until someone manages to figure it out.

SVN-Revision: 2521

16 years agoiso9660: fix joliet version/dot stripping code to handle wide characters.
Andreas Henriksson [Thu, 1 Jul 2010 15:54:04 +0000 (11:54 -0400)] 
iso9660: fix joliet version/dot stripping code to handle wide characters.

Kientzle noticed that test_write_format_iso9660_filename failure
was introduced by rev 2514. See comments at:
http://code.google.com/p/libarchive/source/detail?r=2514

This fixes the problem by not comparing wchar_t against 'x' but L'x'.

SVN-Revision: 2520

16 years agoReflect various merges for 2.8.4. v2.8.4
Joerg Sonnenberger [Wed, 30 Jun 2010 09:56:17 +0000 (05:56 -0400)] 
Reflect various merges for 2.8.4.

SVN-Revision: 2519

16 years agoBasic test for tar --newer-than option. So far, this
Tim Kientzle [Wed, 30 Jun 2010 05:12:57 +0000 (01:12 -0400)] 
Basic test for tar --newer-than option.  So far, this
exercises very basic creation-time filtering and
extraction-time filtering but doesn't yet test the
directory-descent problem documented in Issue 97.
It did uncover a problem with extraction-time filtering
that is fixed here.

SVN-Revision: 2518

16 years agoFix Issue 100: Allow a zero for the Type M Path Table Location, since
Tim Kientzle [Tue, 29 Jun 2010 19:45:25 +0000 (15:45 -0400)] 
Fix Issue 100:  Allow a zero for the Type M Path Table Location, since
WinISO (and probably other programs) set it this way.

SVN-Revision: 2516

16 years agoReport the filename that appeared as a duplicate.
Tim Kientzle [Tue, 29 Jun 2010 19:31:07 +0000 (15:31 -0400)] 
Report the filename that appeared as a duplicate.

SVN-Revision: 2515

16 years agoiso9660/joliet: enable version stripping code.
Andreas Henriksson [Tue, 29 Jun 2010 15:49:49 +0000 (11:49 -0400)] 
iso9660/joliet: enable version stripping code.

This change enables the previously untested code for stripping
off ;1 from filenames.

Some programs (like Nero) always appends versions to the filenames
in the joliet extension, so lets strip it.

This fixes the previously commited testcase ("isojoliet_versioned").

SVN-Revision: 2514

16 years agotest: add joliet iso with versioned files testcase.
Andreas Henriksson [Tue, 29 Jun 2010 15:47:14 +0000 (11:47 -0400)] 
test: add joliet iso with versioned files testcase.

Add test code and a Nero ISO image for testing joliet
code with isos that always append version numbers.

SVN-Revision: 2513

16 years agoMerge r2511:
Joerg Sonnenberger [Mon, 28 Jun 2010 21:44:02 +0000 (17:44 -0400)] 
Merge r2511:
Add two more cases where wcscmp is needed. From Hauke Fath

SVN-Revision: 2512

16 years agoAdd two more cases where wcscmp is needed. From Hauke Fath
Joerg Sonnenberger [Mon, 28 Jun 2010 21:31:24 +0000 (17:31 -0400)] 
Add two more cases where wcscmp is needed. From Hauke Fath

SVN-Revision: 2511

16 years agoMerge r2498:
Joerg Sonnenberger [Sun, 27 Jun 2010 18:51:04 +0000 (14:51 -0400)] 
Merge r2498:
Improve support for systems without modern wctype.h by providing local
versions of wcscpy in test_entry.c and wcscmp in main.c.

SVN-Revision: 2510

16 years agoMerge branches/wstring: This adds a new archive_wstring
Tim Kientzle [Sun, 27 Jun 2010 01:28:00 +0000 (21:28 -0400)] 
Merge branches/wstring:  This adds a new archive_wstring
type for unicode strings and uses it to simplify some
of the code in archive_entry.

SVN-Revision: 2508

16 years agoChoose the copy buffer size used for reading files
Tim Kientzle [Sat, 26 Jun 2010 18:41:38 +0000 (14:41 -0400)] 
Choose the copy buffer size used for reading files
to be archived dynamically:
  * At least 64k
  * At least as large as the -b setting
In particular, this should speed up things noticably when large -b
values are in use.  This is also the first cut at aligning the copy
buffer so we can take advantage of O_DIRECT someday.

SVN-Revision: 2504

16 years agoUse -b setting when interpolating archives.
Tim Kientzle [Sat, 26 Jun 2010 17:18:30 +0000 (13:18 -0400)] 
Use -b setting when interpolating archives.
Simplify the handling of -b values by setting
a default early and then just using the value
instead of duplicating the logic.

SVN-Revision: 2503

16 years agoUse intmax_t for %jd printf arguments.
Tim Kientzle [Sat, 26 Jun 2010 06:17:32 +0000 (02:17 -0400)] 
Use intmax_t for %jd printf arguments.
We should probably be using archive_string_sprintf
here instead of printf to avoid the portability problem
(not all platforms have intmax_t, not all have %jd).

SVN-Revision: 2502

16 years agoVarious tar format improvements:
Tim Kientzle [Fri, 25 Jun 2010 23:26:45 +0000 (19:26 -0400)] 
Various tar format improvements:
 * Improve description of Apple extensions
 * AIX ACL extensions
 * Solaris ACL extensions
 * Move numeric extensions section next to ustar section
 * Add summary of tar header types
 * Add LIBARCHIVE.* pax extensions

SVN-Revision: 2501

16 years agoClear a new fixup_entry. Otherwise, the fixup pass
Tim Kientzle [Fri, 25 Jun 2010 18:31:53 +0000 (14:31 -0400)] 
Clear a new fixup_entry.  Otherwise, the fixup pass
crashes when it tries to free the garbage pointers.

SVN-Revision: 2500

16 years agocast DWORD to int to match %d printf specifier
Tim Kientzle [Fri, 25 Jun 2010 04:03:48 +0000 (00:03 -0400)] 
cast DWORD to int to match %d printf specifier

SVN-Revision: 2499

16 years agoImprove support for systems without modern wctype.h by providing local
Joerg Sonnenberger [Thu, 24 Jun 2010 20:14:41 +0000 (16:14 -0400)] 
Improve support for systems without modern wctype.h by providing local
versions of wcscpy in test_entry.c and wcscmp in main.c.

SVN-Revision: 2498

16 years agoMerge r2495: Fix distribution list to include all cpio testcases.
Joerg Sonnenberger [Mon, 21 Jun 2010 15:27:51 +0000 (11:27 -0400)] 
Merge r2495: Fix distribution list to include all cpio testcases.
Megre r2496: Don't compile in wide char test cases if wcscpy is missing.

SVN-Revision: 2497

16 years agoDon't compile in wide char test cases if wcscpy is missing.
Joerg Sonnenberger [Mon, 21 Jun 2010 12:42:02 +0000 (08:42 -0400)] 
Don't compile in wide char test cases if wcscpy is missing.

SVN-Revision: 2496

16 years agoFix distribution list to include all cpio testcases.
Joerg Sonnenberger [Mon, 21 Jun 2010 12:31:42 +0000 (08:31 -0400)] 
Fix distribution list to include all cpio testcases.

SVN-Revision: 2495

16 years agoMerge 2493:
Joerg Sonnenberger [Sun, 20 Jun 2010 21:24:22 +0000 (17:24 -0400)] 
Merge 2493:
Be nice to ancient bzlib.h, it needs stdio.h.

SVN-Revision: 2494

16 years agoBe nice to ancient bzlib.h, it needs stdio.h.
Joerg Sonnenberger [Sun, 20 Jun 2010 21:22:40 +0000 (17:22 -0400)] 
Be nice to ancient bzlib.h, it needs stdio.h.

SVN-Revision: 2493

16 years agoMerge r2490 and r2491:
Joerg Sonnenberger [Sat, 19 Jun 2010 17:47:04 +0000 (13:47 -0400)] 
Merge r2490 and r2491:
Fall back to getgrgid and getpwuid if the reentrant versions are missing.

SVN-Revision: 2492

16 years agoMust define constants to 1 for #if to work.
Joerg Sonnenberger [Sat, 19 Jun 2010 17:34:15 +0000 (13:34 -0400)] 
Must define constants to 1 for #if to work.

SVN-Revision: 2491

16 years agoFall back to getgrgid and getpwuid if the reentrant versions are missing.
Joerg Sonnenberger [Sat, 19 Jun 2010 17:25:58 +0000 (13:25 -0400)] 
Fall back to getgrgid and getpwuid if the reentrant versions are missing.

SVN-Revision: 2490

16 years agoMerge 2488: Deal with bzip2 before 1.0 by not using it.
Joerg Sonnenberger [Sat, 19 Jun 2010 13:14:17 +0000 (09:14 -0400)] 
Merge 2488: Deal with bzip2 before 1.0 by not using it.

SVN-Revision: 2489

16 years agoDeal with bzip2 before 1.0 by not using it.
Joerg Sonnenberger [Sat, 19 Jun 2010 13:02:48 +0000 (09:02 -0400)] 
Deal with bzip2 before 1.0 by not using it.

SVN-Revision: 2488

16 years agoAdd ARCHIVE_EXTRACT_MAC_METADATA flag to archive_write_disk. This
Tim Kientzle [Sat, 19 Jun 2010 02:48:53 +0000 (22:48 -0400)] 
Add ARCHIVE_EXTRACT_MAC_METADATA flag to archive_write_disk.  This
feeds the mac_metadata blob from the archive_entry to the Mac
copyfile() function to restore ACLs and xattrs.  Restoring these attrs
on dirs is correctly deferred until end-of-archive.

Enable this for tar -p

This is the rest of the support for reading and restoring
Apple extensions to tar archives.

SVN-Revision: 2486