]> git.ipfire.org Git - thirdparty/libarchive.git/log
thirdparty/libarchive.git
12 years agoFix signed integer overflow in safe_fprintf() 27/head
Xi Wang [Fri, 28 Sep 2012 07:04:42 +0000 (03:04 -0400)] 
Fix signed integer overflow in safe_fprintf()

The following "overflow" check in safe_fprintf() invokes undefined
behavior (signed integer overflow), which is incorrect.  Clang will
optimize it away.

int old_length = fmtbuff_length;
fmtbuff_length += fmtbuff_length / 4;
if (old_length > fmtbuff_length) { ... }

The check is in the form:

x > x + x / 4.

As per the C standard, the check is equivalent to:

0 > x / 4,

since x + x / 4 is assumed to not overflow (otherwise undefined).

An earlier check ensures x >= 8192, so this check is always false,
and Clang doesn't emit code for it.

This patch uses unsigned integers to avoid undefined behavior.

12 years agoMinor improvement in the mtree bidder.
Michihiro NAKAJIMA [Wed, 26 Sep 2012 04:04:56 +0000 (13:04 +0900)] 
Minor improvement in the mtree bidder.
 - During checking NetBSD mtree -D format, if the first character of
   the last filed in an entry line is '/', fail the test bidding mtree
   format.

12 years agoBack out of b0eb750cab. It caused several tar/pax test failures.
Michihiro NAKAJIMA [Wed, 26 Sep 2012 02:10:31 +0000 (11:10 +0900)] 
Back out of b0eb750cab. It caused several tar/pax test failures.

12 years agoMerge branch 'mtree-classic'
Michihiro NAKAJIMA [Wed, 26 Sep 2012 01:13:39 +0000 (10:13 +0900)] 
Merge branch 'mtree-classic'

  Add support for generating a mtree classic format(an older formt).

12 years agoUse a character table to check safe characters in filenames in a mtree archive,
Michihiro NAKAJIMA [Tue, 25 Sep 2012 23:52:19 +0000 (08:52 +0900)] 
Use a character table to check safe characters in filenames in a mtree archive,
and add a test for it.

12 years agoMerge pull request #24 from cmdrclueless/tar_read_buffer_overrun_fix
Michihiro NAKAJIMA [Tue, 25 Sep 2012 23:00:29 +0000 (16:00 -0700)] 
Merge pull request #24 from cmdrclueless/tar_read_buffer_overrun_fix

Add tighter checks to avoid reading past end of buffer

12 years agoPlug the possibility of memory leak.
Michihiro NAKAJIMA [Tue, 25 Sep 2012 12:31:52 +0000 (21:31 +0900)] 
Plug the possibility of memory leak.

12 years agoFix bugs introdueced by f87e3db94c.
Michihiro NAKAJIMA [Tue, 25 Sep 2012 11:17:29 +0000 (20:17 +0900)] 
Fix bugs introdueced by f87e3db94c.

12 years agoAdd tighter checks to avoid reading past end of buffer 24/head
Brian Weaver [Tue, 25 Sep 2012 13:51:12 +0000 (09:51 -0400)] 
Add tighter checks to avoid reading past end of buffer

The string to base 8/10 conversion routines could read past the
counted end of the buffer if the string is correctly formated.
The number of characters is now checked and decremented for every
character that is consumed for processing.

12 years agoFix build failure on linux; remove unused variables and a function.
Michihiro NAKAJIMA [Tue, 25 Sep 2012 08:26:38 +0000 (17:26 +0900)] 
Fix build failure on linux; remove unused variables and a function.

12 years agoReduce the amount of memory in mtree writer.
Michihiro NAKAJIMA [Tue, 25 Sep 2012 03:38:03 +0000 (12:38 +0900)] 
Reduce the amount of memory in mtree writer.

12 years agoDisable some mode tests on Windows. We cannot perform it as POSIX systems.
Michihiro NAKAJIMA [Tue, 25 Sep 2012 00:02:17 +0000 (09:02 +0900)] 
Disable some mode tests on Windows. We cannot perform it as POSIX systems.

12 years agoFix build failure on Clang.
Michihiro NAKAJIMA [Mon, 24 Sep 2012 22:25:46 +0000 (07:25 +0900)] 
Fix build failure on Clang.

12 years agoAdd support for writing mtree classic format, which mtree utility generates by default.
Michihiro NAKAJIMA [Fri, 21 Sep 2012 02:51:16 +0000 (11:51 +0900)] 
Add support for writing mtree classic format, which mtree utility generates by default.

12 years agoAllow FreeBSD mtree's nochange keyword.
Michihiro NAKAJIMA [Mon, 24 Sep 2012 22:08:20 +0000 (07:08 +0900)] 
Allow FreeBSD mtree's nochange keyword.

12 years agoFix a mtree detection bug brought by a commit 78307be86b71.
Michihiro NAKAJIMA [Mon, 24 Sep 2012 11:32:42 +0000 (20:32 +0900)] 
Fix a mtree detection bug brought by a commit 78307be86b71.

12 years agoAdd test_utils.h to test_utils_SOURCES, fixes use of 'make dist'.
Andres Mejia [Sat, 22 Sep 2012 00:30:34 +0000 (20:30 -0400)] 
Add test_utils.h to test_utils_SOURCES, fixes use of 'make dist'.

12 years agoDo not write absolute paths to mtree archives.
Michihiro NAKAJIMA [Thu, 20 Sep 2012 05:14:28 +0000 (14:14 +0900)] 
Do not write absolute paths to mtree archives.

12 years agoDo not add "./" prefix to the current directory name ".", it is not necessary.
Michihiro NAKAJIMA [Thu, 20 Sep 2012 04:53:59 +0000 (13:53 +0900)] 
Do not add "./" prefix to the current directory name ".", it is not necessary.
Add test for appending "./" prefix.

12 years agoMerge pull request #20 from allanbrokeit/mtree
Michihiro NAKAJIMA [Thu, 20 Sep 2012 04:10:43 +0000 (21:10 -0700)] 
Merge pull request #20 from allanbrokeit/mtree

Fix mtree generation

12 years agoSeparate test_read_format_mtree to know easily which tests failed.
Michihiro NAKAJIMA [Thu, 20 Sep 2012 03:09:59 +0000 (12:09 +0900)] 
Separate test_read_format_mtree to know easily which tests failed.

12 years agoMerge branch 'master' of github.com:libarchive/libarchive into mtree
Michihiro NAKAJIMA [Thu, 20 Sep 2012 02:39:58 +0000 (11:39 +0900)] 
Merge branch 'master' of github.com:libarchive/libarchive into mtree

12 years agoAdd support for a mtree form that NetBSD's mtree -D generates, which places
Michihiro NAKAJIMA [Thu, 20 Sep 2012 02:34:30 +0000 (11:34 +0900)] 
Add support for a mtree form that NetBSD's mtree -D generates, which places
the path as last parameter.

12 years agoImplement filtering of test cases run using glob pattern matching.
Andres Mejia [Wed, 19 Sep 2012 20:42:10 +0000 (16:42 -0400)] 
Implement filtering of test cases run using glob pattern matching.
A test case will run if it matches a specified glob pattern. Test cases can
also be filtered out by including a '^' at the beginning of a pattern.

12 years agoUpdate .gitignore to ignore library and Testing folder
Andres Mejia [Wed, 19 Sep 2012 18:19:15 +0000 (14:19 -0400)] 
Update .gitignore to ignore library and Testing folder

12 years agoSeperate get_test_set() function out into a utility source file used by all test...
Andres Mejia [Wed, 19 Sep 2012 18:17:54 +0000 (14:17 -0400)] 
Seperate get_test_set() function out into a utility source file used by all test programs.

12 years agoSeperate single RAR test into multiple test cases.
Andres Mejia [Wed, 19 Sep 2012 16:43:19 +0000 (12:43 -0400)] 
Seperate single RAR test into multiple test cases.

12 years agoAdd INCLUDE_DIRECTORIES directive to fix build failure on cmake 2.8.9.
Andres Mejia [Wed, 19 Sep 2012 01:55:41 +0000 (21:55 -0400)] 
Add INCLUDE_DIRECTORIES directive to fix build failure on cmake 2.8.9.

12 years agoFix a possibility of memory leaks when realloc fails.
Michihiro NAKAJIMA [Tue, 18 Sep 2012 11:14:18 +0000 (20:14 +0900)] 
Fix a possibility of memory leaks when realloc fails.
Do not assign the return value of realloc into the variable that has
the original pointer because if realloc failed we will lose the chance
to release the address.

12 years agoFix a part of a commit 221f63f2f8.
Michihiro NAKAJIMA [Tue, 18 Sep 2012 07:39:42 +0000 (16:39 +0900)] 
Fix a part of a commit 221f63f2f8.
The double free bug Clang Static Anlyzer(trunk) claimed of was the Clang's bug,
which is currently fixed, and it made a memory leak.

12 years agoFix build failure on linux made by commit b3296a25e1 to be able to compile
Michihiro NAKAJIMA [Mon, 17 Sep 2012 11:21:13 +0000 (20:21 +0900)] 
Fix build failure on linux made by commit b3296a25e1 to be able to compile
the source file without warnings on gcc and clang.

12 years agoRemove dead assignment that Clang Static Analyzer pointed out.
Michihiro NAKAJIMA [Wed, 12 Sep 2012 01:47:49 +0000 (10:47 +0900)] 
Remove dead assignment that Clang Static Analyzer pointed out.

12 years agoFix bugs that Clang Static Analyzer pointed out:
Michihiro NAKAJIMA [Tue, 11 Sep 2012 11:13:31 +0000 (20:13 +0900)] 
Fix bugs that Clang Static Analyzer pointed out:
 - Memory leak;
 - Result of operation is garbage or undefined;
 - Undefined allocation of 0 bytes.

12 years agoFix use-after-free that Clang Static Analyzer pointed out.
Michihiro NAKAJIMA [Tue, 11 Sep 2012 11:11:09 +0000 (20:11 +0900)] 
Fix use-after-free that Clang Static Analyzer pointed out.

12 years agoFix bugs that Clang Static Analyzer pointed out:
Michihiro NAKAJIMA [Tue, 11 Sep 2012 11:09:30 +0000 (20:09 +0900)] 
Fix bugs that Clang Static Analyzer pointed out:
 - Double free
 - Use-after-free

12 years agoFix a bug that Clang Static Analyzer said "Assigned value is garbage or undefined".
Michihiro NAKAJIMA [Tue, 11 Sep 2012 11:06:25 +0000 (20:06 +0900)] 
Fix a bug that Clang Static Analyzer said "Assigned value is garbage or undefined".

12 years agoFix a memory leak that Clang Static Analyzer pointed out.
Michihiro NAKAJIMA [Tue, 11 Sep 2012 11:01:02 +0000 (20:01 +0900)] 
Fix a memory leak that Clang Static Analyzer pointed out.

12 years agoFix dereference of null pointer that Clang Static Analyzer pointed out.
Michihiro NAKAJIMA [Tue, 11 Sep 2012 10:58:07 +0000 (19:58 +0900)] 
Fix dereference of null pointer that Clang Static Analyzer pointed out.

12 years agoFix a memory leak that Clang Static Analyzer pointed out.
Michihiro NAKAJIMA [Tue, 11 Sep 2012 10:53:17 +0000 (19:53 +0900)] 
Fix a memory leak that Clang Static Analyzer pointed out.

12 years agoRemove dead assignment that Clang Static Analyzer pointed out.
Michihiro NAKAJIMA [Tue, 11 Sep 2012 10:50:28 +0000 (19:50 +0900)] 
Remove dead assignment that Clang Static Analyzer pointed out.

12 years agoFix the failure of archive_read_open_filename_w on Windows.
Michihiro NAKAJIMA [Mon, 10 Sep 2012 07:56:39 +0000 (16:56 +0900)] 
Fix the failure of archive_read_open_filename_w on Windows.
Thas caused test_archive_match_path and test_open_filename failure.

12 years agoFix mtree generation 20/head
Allan McRae [Sat, 8 Sep 2012 08:59:33 +0000 (18:59 +1000)] 
Fix mtree generation

When generating an mtree file, libarchive writes a "Relative" type (entries
that have no /) for files in the base directory. For directories, this causes
the mtree reader to change the parent directory and give subsequent files in
the root directory the wrong path.

Fix this by prefixing entries in the root directory with "./".

12 years agoFix build failure when ACL_TYPE_NFS4 is not defined.
Dan McGee [Wed, 29 Aug 2012 19:52:58 +0000 (15:52 -0400)] 
Fix build failure when ACL_TYPE_NFS4 is not defined.

Signed-off-by: Andres Mejia <amejia004@gmail.com>
12 years agoFix build failure of test_write_compress_lrzip.c, use archive_write_add_filter_lrzip().
Andres Mejia [Wed, 29 Aug 2012 19:52:09 +0000 (15:52 -0400)] 
Fix build failure of test_write_compress_lrzip.c, use archive_write_add_filter_lrzip().

12 years agoFix build failure of test cases using autotools build system.
Andres Mejia [Wed, 29 Aug 2012 19:51:27 +0000 (15:51 -0400)] 
Fix build failure of test cases using autotools build system.

12 years agoMerge pull request #19 from andreas-schwab/master
Tim Kientzle [Wed, 29 Aug 2012 15:10:17 +0000 (08:10 -0700)] 
Merge pull request #19 from andreas-schwab/master

Fix more uses of EXT2_IOC_[GS]ETFLAGS

12 years agoFix more uses of EXT2_IOC_[GS]ETFLAGS 19/head
Andreas Schwab [Wed, 29 Aug 2012 13:41:51 +0000 (15:41 +0200)] 
Fix more uses of EXT2_IOC_[GS]ETFLAGS

12 years agoFix flags on Linux.
Tim Kientzle [Thu, 23 Aug 2012 02:23:48 +0000 (19:23 -0700)] 
Fix flags on Linux.

The ioctl we're using here expects a pointer to an int argument.

12 years agoMerge branch 'master' of github.com:libarchive/libarchive
Tim Kientzle [Mon, 20 Aug 2012 02:57:12 +0000 (19:57 -0700)] 
Merge branch 'master' of github.com:libarchive/libarchive

13 years agoInclude archive_write_disk_acl.c in the autoconf build.
Tim Kientzle [Sun, 5 Aug 2012 18:40:50 +0000 (11:40 -0700)] 
Include archive_write_disk_acl.c in the autoconf build.

13 years agoMerge remote-tracking branch 'origin/master'
Tim Kientzle [Sun, 5 Aug 2012 17:42:05 +0000 (10:42 -0700)] 
Merge remote-tracking branch 'origin/master'

13 years agoAdd a comment suggesting -n with -T.
Tim Kientzle [Thu, 2 Aug 2012 04:45:24 +0000 (21:45 -0700)] 
Add a comment suggesting -n with -T.

13 years agoMerge pull request #16 from mmatuska/master
Tim Kientzle [Wed, 1 Aug 2012 15:33:49 +0000 (08:33 -0700)] 
Merge pull request #16 from mmatuska/master

Add missing variable initialization in FreeBSD acl code.

13 years agoMerge pull request #17 from vx/master
Tim Kientzle [Wed, 1 Aug 2012 05:11:17 +0000 (22:11 -0700)] 
Merge pull request #17 from vx/master

Support appending to empty archives

13 years agoMerge pull request #18 from bradking/rdw-typo
Tim Kientzle [Wed, 1 Aug 2012 05:09:36 +0000 (22:09 -0700)] 
Merge pull request #18 from bradking/rdw-typo

archive_read_disk_windows.c: Fix typo in allocation error message

13 years agoarchive_read_disk_windows.c: Fix typo in allocation error message 18/head
Brad King [Tue, 31 Jul 2012 19:45:43 +0000 (15:45 -0400)] 
archive_read_disk_windows.c: Fix typo in allocation error message

s/direcotry/directory/

13 years agoSupport appending to empty archives. 17/head
Martin Matuska [Tue, 31 Jul 2012 08:41:48 +0000 (10:41 +0200)] 
Support appending to empty archives.

13 years agoAdd missing variable initialization. 16/head
Martin Matuska [Mon, 30 Jul 2012 06:47:09 +0000 (08:47 +0200)] 
Add missing variable initialization.

13 years agoMerge pull request #15 from mbrantner/master
Tim Kientzle [Mon, 23 Jul 2012 04:58:53 +0000 (21:58 -0700)] 
Merge pull request #15 from mbrantner/master

function that allow for switching compression between entries of a zip archive

13 years agoDon't use __func__ or __FUNCTION__: there are too
Tim Kientzle [Mon, 23 Jul 2012 04:55:54 +0000 (21:55 -0700)] 
Don't use __func__ or __FUNCTION__: there are too
many broken compilers in the world.

13 years agoMerge branch 'master' of github.com:libarchive/libarchive
Tim Kientzle [Mon, 23 Jul 2012 04:53:33 +0000 (21:53 -0700)] 
Merge branch 'master' of github.com:libarchive/libarchive

13 years agoMerge pull request #14 from bcran/master
Tim Kientzle [Mon, 23 Jul 2012 04:53:08 +0000 (21:53 -0700)] 
Merge pull request #14 from bcran/master

Fix typos of "Illegal" and "Unknown"

13 years agotwo new functions: 15/head
Matthias Brantner [Fri, 20 Jul 2012 21:20:12 +0000 (14:20 -0700)] 
two new functions:
- archive_write_zip_set_compression_deflate
- archive_write_zip_set_compression_store

which allow to set/switch between compression deflate or store
in between entries of a zip archive

13 years agoMerge branch 'master' of https://github.com/bcran/libarchive 14/head
Bruce Cran [Sat, 30 Jun 2012 20:33:17 +0000 (21:33 +0100)] 
Merge branch 'master' of https://github.com/bcran/libarchive

13 years agoFix Visual C++ 2010 build by using __FUNCTION__
Bruce Cran [Sat, 30 Jun 2012 20:27:29 +0000 (21:27 +0100)] 
Fix Visual C++ 2010 build by using __FUNCTION__

Visual C++ 2010 doesn't understand the C99 __func__ so use the older
(non-standard) __FUNCTION__ instead.

13 years agoVS 2010 doesn't understand __func__ so use the older __FUNCTION__ instead.
Bruce Cran [Sat, 30 Jun 2012 20:27:29 +0000 (21:27 +0100)] 
VS 2010 doesn't understand __func__ so use the older __FUNCTION__ instead.

13 years agoFix typos of "Illegal" and "Unknown".
Bruce Cran [Sat, 30 Jun 2012 20:24:41 +0000 (21:24 +0100)] 
Fix typos of "Illegal" and "Unknown".

13 years agolrzip support isn't legacy, so we don't need legacy shims for it.
Tim Kientzle [Sun, 10 Jun 2012 01:03:58 +0000 (18:03 -0700)] 
lrzip support isn't legacy, so we don't need legacy shims for it.

13 years agoLrzip doesn't have gradations of support.
Tim Kientzle [Sun, 10 Jun 2012 01:01:59 +0000 (18:01 -0700)] 
Lrzip doesn't have gradations of support.

13 years agoOnly test lrzip write filtering if the lrzip executable is available.
Tim Kientzle [Sun, 10 Jun 2012 01:01:29 +0000 (18:01 -0700)] 
Only test lrzip write filtering if the lrzip executable is available.

13 years agoOnly test lrzip extraction if the lrzip executable is available.
Tim Kientzle [Sun, 10 Jun 2012 00:58:25 +0000 (17:58 -0700)] 
Only test lrzip extraction if the lrzip executable is available.

13 years agoAdd canLrzip() utility to probe for existence of lrzip executable on this platform.
Tim Kientzle [Sun, 10 Jun 2012 00:56:21 +0000 (17:56 -0700)] 
Add canLrzip() utility to probe for existence of lrzip executable on this platform.

13 years agoAdd lrzip files to the cmake build.
Tim Kientzle [Sun, 10 Jun 2012 00:55:53 +0000 (17:55 -0700)] 
Add lrzip files to the cmake build.

13 years agoMerge pull request #7 from ckolivas/master
Tim Kientzle [Sun, 10 Jun 2012 00:19:59 +0000 (17:19 -0700)] 
Merge pull request #7 from ckolivas/master

Basic support for lrzip compression and decompression.

13 years agoMerge pull request #13 from naota/master
Tim Kientzle [Sun, 10 Jun 2012 00:01:36 +0000 (17:01 -0700)] 
Merge pull request #13 from naota/master

Avoid infinite loop when there's unsupported acl type

13 years agoAdd archive_write_fail() utility to force a write
Tim Kientzle [Tue, 29 May 2012 20:08:34 +0000 (13:08 -0700)] 
Add archive_write_fail() utility to force a write
handle to abort prematurely.

13 years agoAvoid infinite loop when there's unsupported acl type 13/head
naota [Fri, 25 May 2012 04:03:21 +0000 (13:03 +0900)] 
Avoid infinite loop when there's unsupported acl type

13 years agoFix probable leak with program write add filters. 7/head
Con Kolivas [Mon, 23 Apr 2012 01:04:41 +0000 (11:04 +1000)] 
Fix probable leak with program write add filters.

13 years agoAdd silent build rules for lrzip.
Con Kolivas [Mon, 23 Apr 2012 01:04:13 +0000 (11:04 +1000)] 
Add silent build rules for lrzip.

13 years agoAdd basic archive read and write filter support for lrzip.
Con Kolivas [Mon, 23 Apr 2012 01:03:39 +0000 (11:03 +1000)] 
Add basic archive read and write filter support for lrzip.

13 years agoFix the setup_acls placeholder used on systems where we don't have
Tim Kientzle [Sat, 21 Apr 2012 19:40:15 +0000 (12:40 -0700)] 
Fix the setup_acls placeholder used on systems where we don't have
system-dependent ACL support yet.

13 years agoResuscitate the old NFS4 support code and make it work on FreeBSD-CURRENT.
Tim Kientzle [Mon, 9 Apr 2012 05:06:43 +0000 (22:06 -0700)] 
Resuscitate the old NFS4 support code and make it work on FreeBSD-CURRENT.
This includes a new test that archive_write_disk and archive_read_disk
consistently read/write ACL information to/from disk.
This new test currently passes on FreeBSD-CURRENT.

13 years agoFix the dereference of null pointer, which Clang Static Analyzer complained.
Michihiro NAKAJIMA [Fri, 6 Apr 2012 03:54:47 +0000 (12:54 +0900)] 
Fix the dereference of null pointer, which Clang Static Analyzer complained.

13 years agoFix a memory leak.
Michihiro NAKAJIMA [Fri, 6 Apr 2012 03:40:46 +0000 (12:40 +0900)] 
Fix a memory leak.

13 years agoAvoid a warning that Clang Static Analyzer complained
Michihiro NAKAJIMA [Fri, 6 Apr 2012 03:38:47 +0000 (12:38 +0900)] 
Avoid a warning that Clang Static Analyzer complained
"Access to field 'unconsumed' results in a dereference of a null
 pointer (loaded from field 'entry_cfdata."

13 years agoRemove unneeded code.
Michihiro NAKAJIMA [Fri, 6 Apr 2012 03:34:57 +0000 (12:34 +0900)] 
Remove unneeded code.

13 years agoFix the build failure of libarchive_test on Visual Studio.
Michihiro NAKAJIMA [Thu, 5 Apr 2012 06:59:53 +0000 (15:59 +0900)] 
Fix the build failure of libarchive_test on Visual Studio.

13 years agoFix build failure on Visual Studio.
Michihiro NAKAJIMA [Wed, 4 Apr 2012 08:52:05 +0000 (17:52 +0900)] 
Fix build failure on Visual Studio.

13 years agoFixes for GCC 4.7.0
Dan McGee [Tue, 27 Mar 2012 22:22:40 +0000 (17:22 -0500)] 
Fixes for GCC 4.7.0

Fixes the following compile error exposed with GCC 4.7.0:

    libarchive/archive_string.c: In function 'cesu8_to_unicode':
    libarchive/archive_string.c:2450:11: error: 'wc' may be used uninitialized in this function [-Werror=uninitialized]
    cc1: all warnings being treated as errors

As well as a test failure that depends on signed integer wraparound,
which is a very bad thing to do in C [1]. Mark the intermediate result
as volatile to prevent the compiler optimizing away the arithmetic and
the logical test.

[1] http://www.gnu.org/software/autoconf/manual/autoconf-2.67/html_node/Signed-Overflow-Examples.html

13 years agoInitialize the buffer used for FIEMAP to avoid the error messages
Michihiro NAKAJIMA [Mon, 2 Apr 2012 09:29:48 +0000 (18:29 +0900)] 
Initialize the buffer used for FIEMAP to avoid the error messages
valgrind complains about.

13 years agoOnly look for libmd if OpenSSL is not present.
Tim Kientzle [Mon, 2 Apr 2012 04:06:23 +0000 (21:06 -0700)] 
Only look for libmd if OpenSSL is not present.

In particular, this prevents us from trying to link
both on FreeBSD.

13 years agoMerge pull request #2 from amejia1/multivolume
Tim Kientzle [Wed, 28 Mar 2012 05:26:50 +0000 (22:26 -0700)] 
Merge pull request #2 from amejia1/multivolume

Multivolume File Read Support

13 years agoMerge pull request #11 from toofishes/iso9660
Tim Kientzle [Wed, 28 Mar 2012 05:05:51 +0000 (22:05 -0700)] 
Merge pull request #11 from toofishes/iso9660

Iso9660 fixes and cleanups

13 years agoRemove fallthough-based logic from iso9660 reader 11/head
Dan McGee [Wed, 15 Feb 2012 16:58:23 +0000 (10:58 -0600)] 
Remove fallthough-based logic from iso9660 reader

This simplifies the logic quite a bit, cuts down on code size, and
follows the principle of least surprise.

13 years agoFix segfault in iso9660 reader
Dan McGee [Tue, 27 Mar 2012 22:06:32 +0000 (17:06 -0500)] 
Fix segfault in iso9660 reader

Some odd ISO images do some funny things with RockRidge and Joliet data.
In this particular case, Joliet is used on the CD image, but the first
directory record has no RockRidge data. However, subsequent directory
entries (in the Joliet volume descriptor!) have RockRidge data attached,
although what is noticeably missing are type "NM" or name entries.

This causes seenRockridge to get flipped on, which makes the bad
assumption that seenJoliet is false.  This means that when we reach the
code searching for the "rr_moved" special file, we strcmp() against NULL
because our filename is really in file->utf16be_bytes.

This is by far the easiest fix (and likely most correct fix) to this
madness; I have no idea whether a UTF-16 encoded "rr_moved" file can
even exist with whatever mastering software was used on this ISO.

Also note that if you explicitly disable Joliet processing, you get a
very different file listing on this ISO; apparently this is a cleaver
way to hide files from prying eyes in the Windows world:

    $ ./bsdtar -t --options 'iso9660:joliet' -f example.iso | wc -l
    24
    $ ./bsdtar -t --options 'iso9660:!joliet' -f example.iso | wc -l
    3060

13 years agoUse memcmp to find SP extension bytes
Dan McGee [Tue, 27 Mar 2012 22:06:10 +0000 (17:06 -0500)] 
Use memcmp to find SP extension bytes

13 years agoImplement support for reading multivolume RAR archive files. 2/head
Andres Mejia [Fri, 24 Feb 2012 16:05:00 +0000 (11:05 -0500)] 
Implement support for reading multivolume RAR archive files.

13 years agoImplement support for reading from multiple data objects as one large stream.
Andres Mejia [Fri, 24 Feb 2012 15:57:20 +0000 (10:57 -0500)] 
Implement support for reading from multiple data objects as one large stream.
This enables support for reading archives split using the split utility.

13 years agoChange the default permissions of the regular files in CAB and 7-Zip archives to...
Michihiro NAKAJIMA [Sat, 24 Mar 2012 12:49:14 +0000 (21:49 +0900)] 
Change the default permissions of the regular files in CAB and 7-Zip archives to 0666 as Zip reader.

13 years agoIssue 253: Default to 0666 permissions on files, like Info-Zip does.
Tim Kientzle [Fri, 23 Mar 2012 06:32:23 +0000 (23:32 -0700)] 
Issue 253:  Default to 0666 permissions on files, like Info-Zip does.