summaryrefslogtreecommitdiffstats
path: root/lib/libarchive/test/test_write_disk.c
Commit message (Collapse)AuthorAgeFilesLines
* A raft of test changes and improvements from the Googlecode repository.kientzle2009-12-301-39/+24
| | | | | In particular, this includes tests for the new features I've merged over the last few days.
* Merge from libarchive.googlecode.com: Mostly a bunch ofkientzle2009-04-121-9/+9
| | | | | | | | | | | | | corrections to the Windows support to reconcile differences between Visual Studio and Cygwin. Includes parts of revisions 757, 774, 787, 815, 817, 819, 820, 844, and 886. Of particular note, r886 overhauled the UTF-8/Unicode conversions to work correctly regardless of whether the local system uses 16-bit or 32-bit wchar_t. (I assume that systems with 16-bit wchar_t use UTF-16 and those with 32-bit wchar_t use UCS-4.) This revision also added a preference for wcrtomb() (which is thread-safe) on platforms that support it.
* Merge r718 from libarchive.googlecode.com: Some additionalkientzle2009-03-071-0/+58
| | | | | tests of restoring files to disk with unusual characters, specifically to exercise Windows issues.
* Merge r294:337,r348:350 from libarchive.googlecode.com: A lotkientzle2009-03-031-1/+11
| | | | of work to make libarchive work on Windows.
* MfP4: restore birth time data to disk + more thorough tests forkientzle2008-09-301-0/+1
| | | | | | time restore to disk. MFC after: 30 days
* MfP4: Handle entries with unset size properly: Regular files withkientzle2008-09-051-1/+70
| | | | | | | | unspecified size are "unlimited" (required by Zip reader, which sometimes does not know the uncompressed size of an entry until it gets to the end). Also, hardlinks with unspecified (or zero) size do not overwrite the data on disk nor do they set metadata. This is compatible with GNU tar and NetBSD pax behavior.
* Style: Use ARCHIVE_VERSION_NUMBER to conditionalize tests onkientzle2008-09-011-11/+11
| | | | | the particular libarchive version being tested instead of the deprecated ARCHIVE_API_VERSION and ARCHIVE_VERSION_STAMP macros.
* Use the "start_time" (time at which the restore process began)kientzle2008-09-011-2/+4
| | | | | | to fill in a missing atime instead of substituting mtime. PR: bin/124915
* When atime wasn't specified, it should get set == mtime.kientzle2008-08-301-2/+2
| | | | This is much stronger than just asserting that it's not zero.
* If no atime was specified (for example, when extracting from ustarkientzle2008-08-281-1/+6
| | | | | archives), set atime == mtime. Before this, atime would get restored to 0.
* MfP4: test harness improvements.kientzle2008-06-151-1/+5
|
* Explain a subtle API change that was made recently.kientzle2008-01-231-0/+21
| | | | | | Even though I believe this is a good change, it does have the potential to break certain clients, so it's good to document the reasoning behind the change.
* The previous commit caused the archive_write_disk interface tokientzle2008-01-181-0/+2
| | | | | start obeying filesize limits; this test wasn't properly setting file sizes before trying to write file data.
* Fix the archive_write_data() function so it always returnskientzle2007-09-211-1/+76
| | | | | | | | | | | | | number of bytes written, even when used to write files to disk. Extend the test suite to verify the correct return values for archive_write_data() and archive_write_data_block(). Thanks to: Bruce Mah, for stepping in promptly to back out the earlier broken version of this fix Thanks to: Colin Percival, for pointing out the correct fix MFC after: 5 days Approved by: re (ksmith) Pointy hat: \me
* Revert the last commit to libarchive. It introduced some regresssions,bmah2007-09-181-26/+1
| | | | | | | | | | | most noticably the incorrect extraction of files by bsdtar. This commit reverts: src/lib/libarchive/archive_write_disk.c 1.15 src/lib/libarchive/test/test_write_disk.c 1.4 Approved by: re (implicitly)
* Correct the return value from archive_write_data()kientzle2007-09-181-1/+26
| | | | | | | | | | | (when used to restore files to disk) to match: * The documentation * The return values of this function when used to write files into an archive. Approved by: re (bmah) Pointy hat: \me MFC after: 5 days
* Make test suite work with libarchive 1.3.1: Take advantage ofkientzle2007-07-061-0/+7
| | | | | | | | | | | | | ARCHIVE_VERSION_STAMP to selectively disable tests that don't apply to that version; new "skipping()" function reports skipped tests; modify final summary to report component test failures and skips. Note: I don't currently intend to MFC the test suite itself; anyone interested should just checkout and use this version of the test suite, which should work for any library version. Approved by: re (Ken Smith, blanket)
* libarchive 2.2.3kientzle2007-05-291-9/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | * "compression_program" support uses an external program * Portability: no longer uses "struct stat" as a primary data interchange structure internally * Part of the above: refactor archive_entry to separate out copy_stat() and stat() functions * More complete tests for archive_entry * Finish archive_entry_clone() * Isolate major()/minor()/makedev() in archive_entry; remove these from everywhere else. * Bug fix: properly handle decompression look-ahead at end-of-data * Bug fixes to 'ar' support * Fix memory leak in ZIP reader * Portability: better timegm() emulation in iso9660 reader * New write_disk flags to suppress auto dir creation and not overwrite newer files (for future cpio front-end) * Simplify trailing-'/' fixup when writing tar and pax * Test enhancements: fix various compiler warnings, improve portability, add lots of new tests. * Documentation: document new functions, first draft of libarchive_internals.3 MFC after: 14 days Thanks to: Joerg Sonnenberger (compression_program) Thanks to: Kai Wang (ar) Thanks to: Colin Percival (many small fixes) Thanks to: Many others who sent me various patches and problem reports.
* libarchive 2.0kientzle2007-03-031-0/+92
* libarchive_test program exercises many of the core features * Refactored old "read_extract" into new "archive_write_disk", which uses archive_write methods to put entries onto disk. In particular, you can now use archive_write_disk to create objects on disk without having an archive available. * Pushed some security checks from bsdtar down into libarchive, where they can be better optimized. * Rearchitected the logic for creating objects on disk to reduce the number of system calls. Several common cases now use a minimum number of system calls. * Virtualized some internal interfaces to provide a clearer separation of read and write handling and make it simpler to override key methods. * New "empty" format reader. * Corrected return types (this ABI breakage required the "2.0" version bump) * Many bug fixes.
OpenPOWER on IntegriCloud