summaryrefslogtreecommitdiff
path: root/libarchive
Commit message (Collapse)AuthorAgeFilesLines
* Remove deleted test from makefilesTim Kientzle2013-12-011-2/+1
|
* Remove the redundant test.Tim Kientzle2013-12-012-311/+1
|
* Refactor Zip writer.Tim Kientzle2013-12-017-550/+943
| | | | | | | | | | | | | | | | | | | | | Zip writer no longer preserves full archive_entry objects for every entry; it just accumulates the actual bytes to be put into the central directory. Most of the central directory file header is formatted at the same time as the local file header. The header formatting is refactored to make it easier to support variable-length extra data. The tests are adjusted to match the new output: We include more detailed extra data in the central directory, we're more selective about generating data descriptors (they're not needed for directory entries, for instance), UT extra data now includes only the time fields specified by the user, we're setting the "version required" field more accurately. There are some initial attempts to include Zip64 extensions when appropriate; that still needs lots of work. I'm not yet sure how to test Zip64 support without generating gigantic archives. Hmmm...
* Support Zip64 extra data fields for handling large entries.Tim Kientzle2013-11-267-80/+270
| | | | | | | | | | | Process extra data fields for central directory and local file headers so we get correct full size information in both cases. Correct central directory vs. local file header sanity check to compare full size information (including data picked out of the extra data). Note: This does not yet support the Zip64 end-of-central-directory marker so doesn't correctly handle very large archives.
* Adjust format for longer test names.Tim Kientzle2013-11-261-1/+1
|
* Start refactoring Zip writer:Tim Kientzle2013-11-261-76/+86
| | | | | | | * Build list of entries for Central directory at entry_finish (So we can switch in-memory Central dir to a list of binary blobs.) * Rename some variables to clarify the code. * Add 'zip64' option to force zip64 extensions for testing
* Issue 332: Be more careful guessing file mode information fromTim Kientzle2013-11-244-6/+86
| | | | | incomplete Zip archives. In particular, some epub files have 0 in the file type part of the mode field.
* Merge branch 'master' of github.com:libarchive/libarchiveTim Kientzle2013-11-235-9/+47
|\
| * Avoid struct init with variableBrad King2013-09-261-1/+3
| | | | | | | | | | Compilers such as Borland and MIPSpro do not like struct initialization with variables. Initialize using assignment instead.
| * Merge branch 'no-signed-shift'Brad King2013-09-251-4/+32
| |\
| | * Fix undefined left shift with signed intsSean McBride2012-11-301-4/+32
| | | | | | | | | | | | | | | | | | | | | Caught by Clang's -fsanitize=shift. A small unsigned int was promoted, according to C's regular promotion rules, to a signed int, it was then left shifted. This sometimes pushed a 1 into the sign bit, which is undefined behaviour. Fix by using unsigned temporaries.
| * | Fix chown line in shardump formatTony Morlan2013-09-031-0/+1
| | | | | | | | | | | | Currently the chown line is written with no space before entry name.
| * | Some more test cases around the "2 hours ago" concept.Tim Kientzle2013-09-031-0/+4
| | |
| * | Merge branch 'master' of github.com:libarchive/libarchiveTim Kientzle2013-09-0379-647/+7995
| |\ \
| * | | "now - 2 hours" should be the same as "2 hours ago"Tim Kientzle2012-11-302-4/+7
| | |/ | |/| | | | | | | This was broken by a mis-parsing of the "2 hours" phrase.
* | | Add tests to verify that the seeking Zip reader can correctlyTim Kientzle2013-11-236-21/+156
| | | | | | | | | | | | ignore padding at beginning or end. Fix Issue #257.
* | | Export the seekable and streamable zip readers separatelyTim Kientzle2013-11-231-0/+8
| | | | | | | | | | | | to simplify testing.
* | | Mention the -r option when we can't find our reference files.Tim Kientzle2013-11-231-0/+1
| |/ |/|
* | http://code.google.com/p/libarchive/issues/detail?id=325Tim Kientzle2013-07-121-4/+5
| | | | | | | | Simplify the method/level checks here and fix a bug.
* | Rework the sign-extension to avoid left-shift ofTim Kientzle2013-06-291-11/+7
| | | | | | | | an explicit negative number (which newer GCC complains about).
* | Merge pull request #32 from bamiaux/fix_win32_exclusive_read_accessTim Kientzle2013-04-132-5/+5
|\ \ | | | | | | Do not require exclusive read access when reading files under windows
| * | Do not require exclusive read access when reading files under windowsBenoît Amiaux2013-01-042-5/+5
| | |
* | | Merge pull request #40 from juikim/masterTim Kientzle2013-04-131-2/+4
|\ \ \ | | | | | | | | Do not overwrite file size if the local file header has valid file size.
| * | | Do not overwrite file size if the local file header has valid file size.Jung-uk Kim2013-04-011-2/+4
| | | | | | | | | | | | | | | | This allows us to extract index.xml from Apple iWork '09 format files.
* | | | Issue 314: A tar archive containing only a single 'g' recordTim Kientzle2013-04-104-0/+69
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | should be treated as a valid empty tar archive. (Such archives are generated by 'git archive' from an empty repository.) http://thread.gmane.org/gmane.comp.version-control.git/220485 http://code.google.com/p/libarchive/issues/detail?id=314
* | | | Expose the generic archive_free hookTim Kientzle2013-04-062-6/+14
| | | |
* | | | If seek fails, fail the xar read. We should be able to do better than this.Tim Kientzle2013-04-061-4/+8
|/ / /
* | | Merge pull request #33 from xiw/overflowTim Kientzle2013-03-301-1/+1
|\ \ \ | | | | | | | | Fix overflow checking in archive_entry_sparse_add_entry()
| * | | Fix overflow checking in archive_entry_sparse_add_entry()Xi Wang2013-03-151-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | gcc will optimize the overflow check x + y < 0 (assuming x, y >= 0) into false, since signed integer overflow is undefined behavior in C. Use a safe precondition check instead.
* | | | Limit write requests to at most INT_MAX.Tim Kientzle2013-03-221-0/+5
|/ / / | | | | | | | | | | | | This prevents a certain common programming error (passing -1 to write) from leading to other problems deeper in the library.
* | | Fix test_archive_write_add_filter_by_name_lrzip test case.Andres Mejia2013-02-241-0/+10
| | | | | | | | | | | | | | | | | | There's some bug in lrzip where small files cannot use 2nd stage compression. See http://ck-hack.blogspot.com/2012/03/lrzip-0612.html?showComment=1337356929450#c3154145708572533571
* | | Allow the option to use no 2nd stage compression with lrzip.Andres Mejia2013-02-241-1/+6
| | |
* | | Initialize buff to all zeros.Andres Mejia2013-02-241-1/+1
| | |
* | | Fix test cases for LZO write support.Andres Mejia2013-02-241-8/+9
| | | | | | | | | | | | | | | | | | | | | Some architectures would produce a bigger archive for compression level 9 than with the default level, possibly due to memory limitations. Fixes #303
* | | write_raw support from Marek KubicaTim Kientzle2013-02-239-2/+336
| | | | | | | | | | | | Merged branch 'feature/write-format-raw' of https://github.com/Leonidas-from-XIV/libarchive
* | | Fix compile warning due to -Wcast-qual.Andres Mejia2013-02-221-2/+4
| | |
* | | Fix compiler warning from compiling with clang.Andres Mejia2013-02-211-1/+1
| | | | | | | | | | | | | | | Assigning from a read-only variable to a regular variable will issue a warning from clang.
* | | Add test case for adding pathnames with no leading './' in mtree format.Andres Mejia2013-02-211-0/+123
| | | | | | | | | | | | libarchive should add the leading './' for such pathnames.
* | | mtree: fix line filename length calculation.Dave Reisner2013-02-211-2/+2
| | | | | | | | | | | | | | | Fixes #301. Signed-off-by: Andres Mejia <amejia004@gmail.com>
* | | style fixTim Kientzle2013-02-161-2/+2
| | |
* | | Merge pull request #38 from Leonidas-from-XIV/bugfix/optional-finish-entryTim Kientzle2013-02-161-3/+5
|\ \ \ | | | | | | | | Make calls to the finish_entry callback optional
| * | | Made calls to the finish_entry callback optionalMarek Kubica2013-02-171-3/+5
| | | |
* | | | Redo the strings sorting function, allocate/free memory as needed.Andres Mejia2013-02-091-14/+40
| | | | | | | | | | | | | | | | This is the normal implementation of quicksort.
* | | | Add a convenience function to sort a list of strings.Andres Mejia2013-02-093-0/+107
| | | | | | | | | | | | | | | | | | | | This is useful for sorting a list of filepaths to multivolume RARs for example.
* | | | Bump version to 3.1.2.Andres Mejia2013-02-082-3/+3
| | | |
* | | | Initialize buff, fix valgrind warning about use of uninitialized bytes.Andres Mejia2013-02-071-0/+1
| | | |
* | | | Cast comparison functions to __compar_fn_t if stdlib.h defines it.Andres Mejia2013-02-071-0/+10
| | | |
* | | | Fix warnings about redefinition of variables, use either sys/xattr.h or ↵Andres Mejia2013-02-072-8/+6
| | | | | | | | | | | | | | | | attr/xattr.h.
* | | | Fix warning about unused variable triggered when not building on WIN32.Andres Mejia2013-02-071-0/+2
|/ / /
* | | Partially revert commit 58dc42aaea93cd281aafaaaa4c3926c3578b7e26 as this ↵Andres Mejia2013-02-031-1/+0
| | | | | | | | | | | | broke mingw builds.