]> git.ipfire.org Git - thirdparty/libarchive.git/log
thirdparty/libarchive.git
11 years agoSilently ignore lchmod failure in when not supported 82/head
Romain Fliedel [Fri, 20 Jun 2014 13:45:09 +0000 (15:45 +0200)] 
Silently ignore lchmod failure in when not supported

lchmod might be defined but not supported by the platform,
(this is the case with musl implementation of fchmodat) in
this case we can safely ignore the error.

11 years agoMerge pull request #81 from hroptatyr/feat/format-warc
Tim Kientzle [Tue, 10 Jun 2014 23:26:28 +0000 (16:26 -0700)] 
Merge pull request #81 from hroptatyr/feat/format-warc

Feat/format warc

11 years agoCheck for legal HTTP but illegal unix filenames in WARCs archives. 81/head
Sebastian Freundt [Tue, 10 Jun 2014 13:42:41 +0000 (13:42 +0000)] 
Check for legal HTTP but illegal unix filenames in WARCs archives.

This changeset will refuse to extract WARCs that contain filenames
a la http://example.com/implicit/content/

There is a todo note in archive_read_support_format_warc.c discussing
possible archive options to extract filenames like those either by
explicit user input or by some sort of heuristic as used in wget
for example.

11 years agoSet archive format, and archive format name.
Sebastian Freundt [Tue, 10 Jun 2014 13:03:31 +0000 (13:03 +0000)] 
Set archive format, and archive format name.

This changeset adheres to the previously imported read test.
The archive format is hard-set to ARCHIVE_FORMAT_WARC, while the
format name is the stringified WARC/x.y version designator, which
for performance reasons will be cached between calls to the header
reader _warc_rdhdr().

11 years agoTests, provide known-good archive read test.
Sebastian Freundt [Tue, 10 Jun 2014 12:24:00 +0000 (12:24 +0000)] 
Tests, provide known-good archive read test.

11 years agoHygiene, set unconsumed slot exactly once for each branch
Sebastian Freundt [Tue, 10 Jun 2014 12:46:32 +0000 (12:46 +0000)] 
Hygiene, set unconsumed slot exactly once for each branch

in _warc_read().  Also kick __archive_read_consume() because the writer
will consume the bytes for us.  So for the EOF case, set unconsumed to 0,
for the non-EOF case set unconsumed to the minimum of the number of bytes
read and the content length.

11 years agoHygiene, always use xmemmem() because memmem() is a GNU extension
Sebastian Freundt [Tue, 10 Jun 2014 12:28:18 +0000 (12:28 +0000)] 
Hygiene, always use xmemmem() because memmem() is a GNU extension

11 years agoHygiene, use FALLTHROUGH instead of lint's @fallthrough@
Sebastian Freundt [Tue, 10 Jun 2014 11:20:08 +0000 (11:20 +0000)] 
Hygiene, use FALLTHROUGH instead of lint's @fallthrough@

11 years agoHygiene, trust __archive_read_ahead() and kick superfluous check.
Sebastian Freundt [Tue, 10 Jun 2014 11:15:42 +0000 (11:15 +0000)] 
Hygiene, trust __archive_read_ahead() and kick superfluous check.

Heeding Tim's advice, a non-NULL from __archive_read_ahead() is
guaranteed to be of at least the minimum size, therefore no need to
check for this condition again.

11 years agoHygiene, protect against NULL filenames in _warc_header()
Sebastian Freundt [Tue, 10 Jun 2014 11:01:06 +0000 (11:01 +0000)] 
Hygiene, protect against NULL filenames in _warc_header()

Return ARCHIVE_WARN immediately.

11 years agoFix, an empty WARC archive needs a bit more than 256 bytes.
Sebastian Freundt [Tue, 10 Jun 2014 11:00:20 +0000 (11:00 +0000)] 
Fix, an empty WARC archive needs a bit more than 256 bytes.

11 years agoTests, heed Tim's advice and emit ARCHIVE_FAILED for entries ...
Sebastian Freundt [Tue, 10 Jun 2014 10:40:45 +0000 (10:40 +0000)] 
Tests, heed Tim's advice and emit ARCHIVE_FAILED for entries ...

that cannot be stored (natively) in WARC format.

11 years agoFix compilation on Tru64 with F_SETTIMES
Brad King [Mon, 9 Jun 2014 14:34:32 +0000 (10:34 -0400)] 
Fix compilation on Tru64 with F_SETTIMES

The parent commit left a typo in the conditional code path for Tru64.
Add the missing '.'.

11 years agoFix compilation on newer HP-UX versions
Rolf Eike Beer [Fri, 6 Jun 2014 15:44:16 +0000 (17:44 +0200)] 
Fix compilation on newer HP-UX versions

Newer HP-UX versions (e.g. 11.31) also offers F_SETTIMES, but with a
different struct for the timing information.

Suggested-by: Eric Berge <ericmberge@gmail.com>
11 years agoIssue #359: Rar drops file if previous filename is a prefix
Tim Kientzle [Wed, 4 Jun 2014 23:57:42 +0000 (16:57 -0700)] 
Issue #359:  Rar drops file if previous filename is a prefix

11 years agoHygiene, clean up xmemmem() code a little, use xor sums.
Sebastian Freundt [Fri, 23 May 2014 08:36:54 +0000 (08:36 +0000)] 
Hygiene, clean up xmemmem() code a little, use xor sums.

Signed-off-by: Sebastian Freundt <freundt@ga-group.nl>
11 years agoStore and read back mtimes through Last-Modified custom header
Sebastian Freundt [Fri, 23 May 2014 08:19:02 +0000 (08:19 +0000)] 
Store and read back mtimes through Last-Modified custom header

Signed-off-by: Sebastian Freundt <freundt@ga-group.nl>
11 years agoFix, actually consume data between calls to _warc_read()
Sebastian Freundt [Wed, 21 May 2014 15:18:41 +0000 (15:18 +0000)] 
Fix, actually consume data between calls to _warc_read()

11 years agoObey gcc warnings,
Sebastian Freundt [Wed, 21 May 2014 14:32:05 +0000 (14:32 +0000)] 
Obey gcc warnings,

in particular: Don't compare integers of different signedness,
always initialise all members of a struct explicitly.

11 years agofix, WARC files urgently need the filesize to be known when the header is written
Sebastian Freundt [Wed, 21 May 2014 14:11:32 +0000 (14:11 +0000)] 
fix, WARC files urgently need the filesize to be known when the header is written

11 years agofix, request just the bare minimum for a WARC header
Sebastian Freundt [Wed, 21 May 2014 14:10:48 +0000 (14:10 +0000)] 
fix, request just the bare minimum for a WARC header

Moreover, assume a response of less than the bare minimum header
length to be the archive's EOF.

11 years agofix, never write more bytes in _warc_data() than ...
Sebastian Freundt [Wed, 21 May 2014 12:32:50 +0000 (12:32 +0000)] 
fix, never write more bytes in _warc_data() than ...

previously announce in _warc_header().

The test suite (as is) is one offender.  It populates a 9-byte string, mimicking an IFREG file
but by the time the header makes it into the archive, the size changes from 0 to 9.

11 years agoProvide WARC read/write tests
Sebastian Freundt [Wed, 21 May 2014 11:24:55 +0000 (11:24 +0000)] 
Provide WARC read/write tests

11 years agoImplant WARC support in tar's get_format_code()
Sebastian Freundt [Wed, 21 May 2014 11:20:35 +0000 (11:20 +0000)] 
Implant WARC support in tar's get_format_code()

11 years agoProvide ISO 28500:2009 reader (aka warc, aka web archive)
Sebastian Freundt [Tue, 20 May 2014 13:26:50 +0000 (13:26 +0000)] 
Provide ISO 28500:2009 reader (aka warc, aka web archive)

11 years agoProvide ISO 28500:2009 writer (aka warc, aka web archive)
Sebastian Freundt [Tue, 20 May 2014 08:19:38 +0000 (08:19 +0000)] 
Provide ISO 28500:2009 writer (aka warc, aka web archive)

11 years agoMerge pull request #80 from sergiud/master
Tim Kientzle [Sat, 10 May 2014 04:00:30 +0000 (21:00 -0700)] 
Merge pull request #80 from sergiud/master

Check whether file handle is valid

11 years agocheck handle validity when closing a file 80/head
Sergiu Dotenco [Mon, 5 May 2014 14:18:51 +0000 (16:18 +0200)] 
check handle validity when closing a file

This eliminates an assertion under Windows that occurs when an archive cannot be
opened.

11 years agoZip: Adjust streaming extension field to match the final spec worked out with Info...
Tim Kientzle [Sun, 4 May 2014 05:59:31 +0000 (22:59 -0700)] 
Zip: Adjust streaming extension field to match the final spec worked out with Info-Zip folks

11 years agoMerge pull request #79 from maksqwe/duplicate_expression_fix
Tim Kientzle [Thu, 17 Apr 2014 01:08:28 +0000 (18:08 -0700)] 
Merge pull request #79 from maksqwe/duplicate_expression_fix

Remove duplicate expressions

11 years agoremove duplicate expressions in file_information() 79/head
Maks Naumov [Wed, 16 Apr 2014 22:03:53 +0000 (01:03 +0300)] 
remove duplicate expressions in file_information()

11 years agoremove duplicate expressions in entry_copy_bhfi()
Maks Naumov [Wed, 16 Apr 2014 22:02:39 +0000 (01:02 +0300)] 
remove duplicate expressions in entry_copy_bhfi()

11 years agoMerge pull request #77 from biometrics/additional_libs_scope
Tim Kientzle [Wed, 16 Apr 2014 01:56:37 +0000 (18:56 -0700)] 
Merge pull request #77 from biometrics/additional_libs_scope

just link the archive_static with ADDITIONAL_LIBS

11 years agojust link the archive_static with ADDITIONAL_LIBS 77/head
Josh Klontz [Tue, 15 Apr 2014 20:53:41 +0000 (16:53 -0400)] 
just link the archive_static with ADDITIONAL_LIBS

11 years agoMerge pull request #76 from biometrics/additional_libs_scope
Tim Kientzle [Tue, 15 Apr 2014 02:19:05 +0000 (19:19 -0700)] 
Merge pull request #76 from biometrics/additional_libs_scope

fixed 'current scope has no parent' warning

11 years agofixed 'current scope has no parent' warning 76/head
Josh Klontz [Mon, 14 Apr 2014 20:48:10 +0000 (16:48 -0400)] 
fixed 'current scope has no parent' warning

11 years agoAdd lafe files to cat project
Tim Kientzle [Sat, 12 Apr 2014 20:56:29 +0000 (13:56 -0700)] 
Add lafe files to cat project

11 years agoAdd missing file.
Tim Kientzle [Sat, 12 Apr 2014 20:56:04 +0000 (13:56 -0700)] 
Add missing file.

11 years agoMerge pull request #69 from ice799/fix_shadowing
Tim Kientzle [Sat, 12 Apr 2014 16:50:11 +0000 (09:50 -0700)] 
Merge pull request #69 from ice799/fix_shadowing

Fix shadowing warning for identifier symlink

11 years agoMerge pull request #74 from mk-fg/add_bsdcat_tests
Tim Kientzle [Sat, 12 Apr 2014 16:49:24 +0000 (09:49 -0700)] 
Merge pull request #74 from mk-fg/add_bsdcat_tests

Add bsdcat tests

11 years agoMerge pull request #75 from biometrics/additional_libs_scope
Tim Kientzle [Sat, 12 Apr 2014 16:45:07 +0000 (09:45 -0700)] 
Merge pull request #75 from biometrics/additional_libs_scope

Expose ADDITIONAL_LIBS

11 years agoExpose ADDITIONAL_LIBS for projects using libarchive as a subdirectory and linking... 75/head
Josh Klontz [Sat, 12 Apr 2014 14:25:48 +0000 (10:25 -0400)] 
Expose ADDITIONAL_LIBS for projects using libarchive as a subdirectory and linking against archive_static.

11 years agoAdd basic tests for bsdcat. 74/head
Mike Kazantsev [Tue, 8 Apr 2014 21:22:22 +0000 (03:22 +0600)] 
Add basic tests for bsdcat.

11 years agoExit with error status from bsdcat if any errors occurred.
Mike Kazantsev [Tue, 8 Apr 2014 19:24:59 +0000 (01:24 +0600)] 
Exit with error status from bsdcat if any errors occurred.

11 years agoReturn success exit code from "bsdcat --help" and print usage to stdout.
Mike Kazantsev [Tue, 8 Apr 2014 19:19:48 +0000 (01:19 +0600)] 
Return success exit code from "bsdcat --help" and print usage to stdout.

11 years agoAdd missing backslash before bsdcat_EXTRA_DIST.
Mike Kazantsev [Tue, 8 Apr 2014 18:32:04 +0000 (00:32 +0600)] 
Add missing backslash before bsdcat_EXTRA_DIST.

11 years agoSort .gitignore, add cat deps/dirstamp files.
Mike Kazantsev [Tue, 8 Apr 2014 18:31:09 +0000 (00:31 +0600)] 
Sort .gitignore, add cat deps/dirstamp files.

11 years agoMerge pull request #73 from betafive/pbarker/deflate
Tim Kientzle [Mon, 7 Apr 2014 01:05:41 +0000 (18:05 -0700)] 
Merge pull request #73 from betafive/pbarker/deflate

Prevent unnecessary linking against deflate code

11 years agoMerge pull request #72 from betafive/pbarker/fix-zip
Tim Kientzle [Mon, 7 Apr 2014 01:02:59 +0000 (18:02 -0700)] 
Merge pull request #72 from betafive/pbarker/fix-zip

Fix intermittent segfault when reading zip files

11 years agoMerge pull request #70 from mk-fg/add_bsdcat_tool
Tim Kientzle [Mon, 7 Apr 2014 01:00:04 +0000 (18:00 -0700)] 
Merge pull request #70 from mk-fg/add_bsdcat_tool

Add optional bsdcat tool

11 years agoMinor style correction in bsdcat. 70/head
Mike Kazantsev [Sun, 6 Apr 2014 22:30:49 +0000 (04:30 +0600)] 
Minor style correction in bsdcat.

11 years agoUse snprintf to print to zip->format_name 72/head
Paul Barker [Sun, 6 Apr 2014 22:12:26 +0000 (23:12 +0100)] 
Use snprintf to print to zip->format_name

zip->format_name is a fixed size character array so ensure that the number of
characters written to the array is appropriately limited.

Signed-off-by: Paul Barker <paul@paulbarker.me.uk>
11 years agoFix intermittent segfault when reading zip files
Paul Barker [Sun, 6 Apr 2014 21:54:48 +0000 (22:54 +0100)] 
Fix intermittent segfault when reading zip files

When looking up the compression name for a zip file the index variable was being
incremented too soon. Thus element zero ("uncompressed") was never checked and
reads could be made past the end of the array. This was causing intermittent
segfaults in the call to sprintf in zip_read_local_file_header.

Signed-off-by: Paul Barker <paul@paulbarker.me.uk>
11 years agoPrevent unnecessary linking against deflate code 73/head
Paul Barker [Thu, 6 Feb 2014 21:20:06 +0000 (21:20 +0000)] 
Prevent unnecessary linking against deflate code

In _archive_write_disk_free, the call to deflateEnd was compiled if HAVE_ZLIB_H
was defined. However, all other calls to deflate functions were only compiled
if __APPLE__, UF_COMPRESSED and HAVE_SYS_XATTR_H were also defined. So if one of
these macros was not defined but HAVE_ZLIB_H was defined, the call the
deflateEnd would be unnecessary as deflateInit could never have been called.

In statically linked applications which don't use deflate functions elsewhere
this was causing unnecessary linking of the deflate code from zlib, adding at
least 20k of object code to the final executable size.

This patch fixes the above issue by surrounding the call to deflateEnd with the
same conditional compilation checks as surround the call to deflateInit.

Signed-off-by: Paul Barker <paul@paulbarker.me.uk>
11 years agoMerge pull request #71 from betafive/pbarker/extract
Tim Kientzle [Sun, 6 Apr 2014 17:47:11 +0000 (10:47 -0700)] 
Merge pull request #71 from betafive/pbarker/extract

Split archive_read_extract.c into two source files

11 years agoSplit archive_read_extract2 from archive_read_extract 71/head
Paul Barker [Sun, 6 Apr 2014 14:48:24 +0000 (15:48 +0100)] 
Split archive_read_extract2 from archive_read_extract

The function archive_read_extract requires a call to
archive_write_disk_set_standard_lookup but the functions archive_read_extract2
and archive_read_extract_set_progress_callback do not. Therefore, the latter
pair of functions, the internal function __archive_read_get_extract and the
static function copy_data are moved out of archive_read_extract.c into the new
file archive_read_extract2.c.

This ensures that when statically linking, the standard user and group lookup
functions will not be linked into a program unless they are really needed.

Signed-off-by: Paul Barker <paul@paulbarker.me.uk>
11 years agoRefactor archive_read_extract
Paul Barker [Sun, 6 Apr 2014 13:37:03 +0000 (14:37 +0100)] 
Refactor archive_read_extract

The initialisation of the archive_write_disk object and the call to
archive_write_disk_set_standard_lookup are only needed in the
archive_read_extract function, not in archive_read_extract2 or other related
functions. Therefore this initialisation is merged into archive_read_extract.

The static function get_extract is renamed to __archive_read_get_extract so that
is can be made non-static. The struct extract is renamed to archive_read_extract
so that it can be placed in a header file without risk of namespace clashes.
Both these declarations are then moved to the archive_read_private.h header.
This preparation is necessary so that the contents of archive_read_extract.c can
be split between two source files.

Signed-off-by: Paul Barker <paul@paulbarker.me.uk>
11 years agoMinor cleanup of a redundant check in bsdcat cli parsing.
Mike Kazantsev [Sat, 5 Apr 2014 22:55:02 +0000 (04:55 +0600)] 
Minor cleanup of a redundant check in bsdcat cli parsing.

11 years agoChange bsdcat behavior to process as many files as possible.
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.

11 years agoUse getopt() instead of getopt_long() in bsdcat for compatibility reasons.
Mike Kazantsev [Sat, 5 Apr 2014 22:33:26 +0000 (04:33 +0600)] 
Use getopt() instead of getopt_long() in bsdcat for compatibility reasons.

11 years agoAdd optional bsdcat tool.
Mike Kazantsev [Fri, 4 Apr 2014 09:59:15 +0000 (15:59 +0600)] 
Add optional bsdcat tool.

bsdcat works like zcat, bzcat, xzcat and similar tools, but auto-detects
source data format, which can also vary between multiple input files.

11 years agoFix shadowing warning for identifier symlink 69/head
Joe Damato [Mon, 24 Mar 2014 08:32:11 +0000 (08:32 +0000)] 
Fix shadowing warning for identifier symlink

11 years agoMerge pull request #68 from guidefloripa/master
Tim Kientzle [Tue, 18 Mar 2014 03:43:07 +0000 (20:43 -0700)] 
Merge pull request #68 from guidefloripa/master

Fix memory leak for 7zip/xz

11 years agoUpdate xz compatibility for reading xz. 68/head
Guilherme Steinmann [Mon, 17 Mar 2014 13:10:55 +0000 (10:10 -0300)] 
Update xz compatibility for reading xz.

11 years agoUpdate xz compatibility for reading 7zip.
Guilherme Steinmann [Mon, 17 Mar 2014 13:01:59 +0000 (10:01 -0300)] 
Update xz compatibility for reading 7zip.

11 years agoMerge pull request #63 from sergiud/master
Tim Kientzle [Sun, 16 Mar 2014 17:27:20 +0000 (10:27 -0700)] 
Merge pull request #63 from sergiud/master

Do not redefine _WIN32_WINNT and WINVER

11 years agoMerge pull request #61 from kevinoid/ignore_zeros
Tim Kientzle [Sun, 16 Mar 2014 17:25:49 +0000 (10:25 -0700)] 
Merge pull request #61 from kevinoid/ignore_zeros

Add --ignore-zeros option to bsdtar

11 years agoMerge pull request #55 from NiLuJe/cmake-pkgconfig
Tim Kientzle [Sun, 16 Mar 2014 17:23:20 +0000 (10:23 -0700)] 
Merge pull request #55 from NiLuJe/cmake-pkgconfig

Make the CMake build more pkg-config friendly

11 years agoMerge pull request #67 from jmalak/master
Tim Kientzle [Sun, 16 Mar 2014 17:20:45 +0000 (10:20 -0700)] 
Merge pull request #67 from jmalak/master

fixes to build by Open Watcom toolchain

11 years agofixes for test programs to be buildable by Open Watcom 67/head
Jiri Malak [Wed, 12 Mar 2014 07:50:51 +0000 (08:50 +0100)] 
fixes for test programs to be buildable by Open Watcom

correct buffers to be realy local for each test as expected by logic

11 years agorest of changes to be buildable by Open Watcom
Jiri Malak [Wed, 12 Mar 2014 07:02:37 +0000 (08:02 +0100)] 
rest of changes to be buildable by Open Watcom

11 years agofixes to build by Open Watcom toolchain
Jiri Malak [Wed, 12 Mar 2014 06:32:22 +0000 (07:32 +0100)] 
fixes to build by Open Watcom toolchain

11 years agoMerge pull request #65 from Bluewind/working
Tim Kientzle [Sun, 2 Mar 2014 17:20:46 +0000 (09:20 -0800)] 
Merge pull request #65 from Bluewind/working

mtree: Make reading additional information from the fs optional

11 years agomtree: Make reading additional information from the fs optional 65/head
Florian Pritz [Sat, 1 Mar 2014 16:21:47 +0000 (17:21 +0100)] 
mtree: Make reading additional information from the fs optional

This feature is not needed if users just want to read in the content of
an mtree file and do validation against the file system themselves.

It is needed for `bsdtar cvf out.tar @input.mtree` which is why the
option is enabled in bsdtar.

Since the mtree tests rely on this feature, this patch also enables it
there.

Signed-off-by: Florian Pritz <bluewind@xinu.at>
11 years agoReturn correct error when multiple modules match an option spec
Tim Kientzle [Sun, 23 Feb 2014 17:34:43 +0000 (09:34 -0800)] 
Return correct error when multiple modules match an option spec

11 years agostreaming zip reader does not support mac extensions
Tim Kientzle [Sun, 23 Feb 2014 17:33:44 +0000 (09:33 -0800)] 
streaming zip reader does not support mac extensions

11 years agoEnable mac extensions for mac extension test
Tim Kientzle [Sun, 23 Feb 2014 17:17:22 +0000 (09:17 -0800)] 
Enable mac extensions for mac extension test

11 years agoFix: process directory entries even when mac extensions are turned off
Tim Kientzle [Sun, 23 Feb 2014 17:16:34 +0000 (09:16 -0800)] 
Fix: process directory entries even when mac extensions are turned off

11 years agoZip: Make Mac extension handling optional with "mac-ext" option for Zip, default...
Tim Kientzle [Sun, 23 Feb 2014 16:49:02 +0000 (08:49 -0800)] 
Zip: Make Mac extension handling optional with "mac-ext" option for Zip, default true on Mac OS"

11 years agoMerge remote-tracking branch 'upstream/master' into cmake-pkgconfig 55/head
NiLuJe [Sun, 16 Feb 2014 18:53:01 +0000 (19:53 +0100)] 
Merge remote-tracking branch 'upstream/master' into cmake-pkgconfig

11 years agoMerge pull request #64 from NiLuJe/fix-warning
Tim Kientzle [Sun, 16 Feb 2014 18:48:15 +0000 (10:48 -0800)] 
Merge pull request #64 from NiLuJe/fix-warning

Fix a couple of minor warnings.

11 years agoDo not redefine _WIN32_WINNT and WINVER 63/head
Sergiu Dotenco [Mon, 27 Jan 2014 13:51:10 +0000 (14:51 +0100)] 
Do not redefine _WIN32_WINNT and WINVER

11 years agoFix a couple of minor warnings. 64/head
NiLuJe [Sat, 25 Jan 2014 00:24:24 +0000 (01:24 +0100)] 
Fix a couple of minor warnings.

Just so that the build passes w/ -Werror

11 years agoMerge remote-tracking branch 'upstream/master' into cmake-pkgconfig
NiLuJe [Fri, 24 Jan 2014 21:34:52 +0000 (22:34 +0100)] 
Merge remote-tracking branch 'upstream/master' into cmake-pkgconfig

11 years agoMake the backslash line continuations more consistent for automatic updating; update...
Tim Kientzle [Fri, 17 Jan 2014 04:12:49 +0000 (20:12 -0800)] 
Make the backslash line continuations more consistent for automatic updating; update the libarchive test data

11 years agoFix the zip tests that were inadvertently disabled (and hence broken).
Tim Kientzle [Fri, 17 Jan 2014 04:02:05 +0000 (20:02 -0800)] 
Fix the zip tests that were inadvertently disabled (and hence broken).

Extend them to verify with/without forcing zip64 and with/without 'el' extension.

11 years agoInclude missing test in cmake build, sort the file list.
Tim Kientzle [Fri, 17 Jan 2014 04:01:44 +0000 (20:01 -0800)] 
Include missing test in cmake build, sort the file list.

11 years agoInclude tests for new zip64 functionality in autoconf-based build.
Tim Kientzle [Fri, 17 Jan 2014 04:01:17 +0000 (20:01 -0800)] 
Include tests for new zip64 functionality in autoconf-based build.

11 years agoFix out-of-tree build
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>
11 years agoMerge pull request #62 from kientzle/master
Tim Kientzle [Thu, 16 Jan 2014 15:50:50 +0000 (07:50 -0800)] 
Merge pull request #62 from kientzle/master

Zip64 refactoring

11 years agoAdd --ignore-zeros option to bsdtar 61/head
Kevin Locke [Wed, 15 Jan 2014 03:05:40 +0000 (20:05 -0700)] 
Add --ignore-zeros option to bsdtar

This option is an alias for --options read_concatenated_archive
introduced for compatibility with GNU tar.

Signed-off-by: Kevin Locke <kevin@kevinlocke.name>
11 years agoDo not require LibXml2 to configure
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.

11 years agoMerge pull request #59 from NiLuJe/fix-warning
Tim Kientzle [Mon, 13 Jan 2014 02:26:18 +0000 (18:26 -0800)] 
Merge pull request #59 from NiLuJe/fix-warning

Fix a minor sign issue.

11 years agoAdd a test for read_concatenated_archives 60/head
Kevin Locke [Sat, 11 Jan 2014 23:40:16 +0000 (16:40 -0700)] 
Add a test for read_concatenated_archives

Make sure that we are reading the concatenated contents when requested
and only when requested.

Signed-off-by: Kevin Locke <kevin@kevinlocke.name>
11 years ago[PATCH v3] Add read_concatenated_archives
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>
11 years agoVerify that Zip writer rejects too-large files when Zip64 is disabled. 62/head
Tim Kientzle [Sun, 12 Jan 2014 19:45:53 +0000 (11:45 -0800)] 
Verify that Zip writer rejects too-large files when Zip64 is disabled.

Interestingly, this found a bug in the write core:  if the
writer rejects a file, the write core would erroneously transition to
state DATA.

11 years agoVerify the end-of-archive information as part of the large zip test.
Tim Kientzle [Sun, 12 Jan 2014 19:21:02 +0000 (11:21 -0800)] 
Verify the end-of-archive information as part of the large zip test.

Fix a bug that breaks compat with Info-Zip 'unzip' program.

11 years agoMerge branch 'master' of github.com:kientzle/libarchive-zip64
Tim Kientzle [Sun, 12 Jan 2014 17:18:57 +0000 (09:18 -0800)] 
Merge branch 'master' of github.com:kientzle/libarchive-zip64

11 years agoOnly consume a second all-null record
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>
11 years agoOnly enable the still-experimental 'el' extra block
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.