Mike Kazantsev [Sat, 5 Apr 2014 22:40:40 +0000 (04:40 +0600)]
Change bsdcat behavior to process as many files as possible.
Change is to match "cat" behavior of printing any errors (e.g. "unable to
open file") and continue to the next file instead of exiting on first error
encountered.
Paul Barker [Thu, 16 Jan 2014 15:16:31 +0000 (15:16 +0000)]
Fix out-of-tree build
When building outside the source tree, the directories 'libarchive/test',
'tar/test' and 'cpio/test' need to be created before the commands in Makefile.am
are executed which create list.h files in these directories.
Signed-off-by: Paul Barker <paul@paulbarker.me.uk>
Brad King [Mon, 13 Jan 2014 14:36:15 +0000 (09:36 -0500)]
Do not require LibXml2 to configure
In commit 033fc31e (Allow fine grained control over dependancies,
2013-05-16, committed 2013-12-12) the find_package(LibXml2) line was
accidentally given a REQUIRED specifier. Remove it now.
Kevin Locke [Sat, 11 Jan 2014 23:38:52 +0000 (16:38 -0700)]
[PATCH v3] Add read_concatenated_archives
As discussed in http://code.google.com/p/libarchive/issues/detail?id=348
the read_concatenated_archives option provides functionality similar to
the GNUtar --ignore-zeros option in order to support reading from
archives which have been concatenated together.
Changes in v2:
* Replace recursion with looping for reading concatenated archives.
Changes in v3:
* Improve comments about archive format detection and looping when
reading concatenated archives.
Signed-off-by: Kevin Locke <kevin@kevinlocke.name>
Kevin Locke [Sat, 11 Jan 2014 23:35:21 +0000 (16:35 -0700)]
Only consume a second all-null record
Currently any record following an all-null record will be consumed.
This is probably not the intended behavior, as it does not match the
comment and consumes/ignores unexpected and unrecognized data. In
particular, for the read_concatenated_archives case, it could
incorrectly consume a non-null header.
Signed-off-by: Kevin Locke <kevin@kevinlocke.name>
Tim Kientzle [Thu, 9 Jan 2014 05:20:10 +0000 (21:20 -0800)]
Only enable the still-experimental 'el' extra block
if option 'zip:experimental' is specified.
This should limit the use of this option until the
final format is actually nailed down.
Tim Kientzle [Mon, 30 Dec 2013 04:57:17 +0000 (20:57 -0800)]
Support experimental "at" extra block for better streaming.
The writer now writes this extra block with every local
file header; the reader recognizes it and uses it.
This allows streaming extraction to properly restore
file permissions and symlinks.
Without this, streaming extraction of Zip archives is
somewhat hobbled by the lack of full information in
the local file header.
Here's a detailed description of the new extra block.
The details here are subject to change at any time.
-Extended Local File Header Extra Field (0x7461):
The following is the layout of the extended local file
header "extra" block. This allows information to be
included with the local file header that could previously
only be stored with the central directory file header.
Note: all fields stored in Intel low-byte/high-byte order.
Value Size Description
----- ---- -----------
0x7461 2 bytes Tag for this "extra" block type
Size 2 bytes Size of this "extra" block
Version
Made By 2 bytes See "Version Made By" above
Internal File
Attributes 2 bytes See "Internal File Attributes" above
External File
Attributes 4 bytes See "External File Attributes" above
This extra block should only be used with the local
file header. The values stored should exactly match
the corresponding values in the central directory
file header.
Tim Kientzle [Sat, 28 Dec 2013 09:45:32 +0000 (01:45 -0800)]
Test for large Zip archives, following code for large Tar test.
Fix several bugs:
* comparison function for ordering entries in reader was wrong
* writer wasn't including 64-bit sizes for entries of exactly 0xffffffff bytes
Also, add options to suppress CRC calculations and checks
(otherwise, this test spends a *lot* of time in CRC routines).
Tim Kientzle [Thu, 26 Dec 2013 21:59:55 +0000 (13:59 -0800)]
Fix all current tests:
* When searching for start of Central directory, DTRT if there are no entries.
* Find end-of-archive marker when it is exactly at end of file
* Recognize zip64 central directory locator (not yet fully parsed)
* Don't return entry size if length-at-end, even if size looks reasonable