]> git.ipfire.org Git - thirdparty/libarchive.git/log
thirdparty/libarchive.git
15 years agoFix size_t and ssize_t defaults on Borland
Brad King [Wed, 11 Nov 2009 14:20:14 +0000 (09:20 -0500)] 
Fix size_t and ssize_t defaults on Borland

We use more generic decision tests to select these types.  The new tests
choose the proper types for Borland while preserving reasonable defaults
for other compilers.

SVN-Revision: 1641

15 years agoFix uid_t, git_t, dev_t, and mode_t on Borland
Brad King [Wed, 11 Nov 2009 14:20:08 +0000 (09:20 -0500)] 
Fix uid_t, git_t, dev_t, and mode_t on Borland

SVN-Revision: 1640

15 years agoSelect stdint.h or inttypes.h in archive.h
Brad King [Wed, 11 Nov 2009 14:20:01 +0000 (09:20 -0500)] 
Select stdint.h or inttypes.h in archive.h

Since archive.h cannot use try-compile results it must memorize the
availability of integer type headers for every platform.  We split the
decision of which header to use out from the actual #include line by
defining __LA_STDINT_H to the chosen header.

SVN-Revision: 1639

15 years agoDo not redefine stat and file mode macros
Brad King [Wed, 11 Nov 2009 14:19:55 +0000 (09:19 -0500)] 
Do not redefine stat and file mode macros

Some windows compilers define macros like O_RDONLY and S_ISBLK with
leading underscores (e.g. _O_RDONLY and _S_ISBLK).  In our windows
compatibility header "archive_windows.h" we define the non-prefixed
names so that the rest of our code can use them everywhere.  However,
some windows compilers also define the non-prefixed names.  On these
compilers we should not redefine them.

SVN-Revision: 1638

15 years agoUse setmode compatiblity macro on Windows
Brad King [Wed, 11 Nov 2009 14:19:49 +0000 (09:19 -0500)] 
Use setmode compatiblity macro on Windows

Instead of duplicating preprocessor tests to call setmode or _setmode,
we define setmode to _setmode on Windows.

SVN-Revision: 1637

15 years agoProvide SetFilePointerEx for VS 6
Brad King [Wed, 11 Nov 2009 14:19:40 +0000 (09:19 -0500)] 
Provide SetFilePointerEx for VS 6

Visual Studio 6 does not provide SetFilePointerEx in its Windows API.
We implement it in terms of SetFilePointer for that compiler.

SVN-Revision: 1636

15 years agoUse macro for 64-bit integer literal suffixes
Brad King [Wed, 11 Nov 2009 14:19:34 +0000 (09:19 -0500)] 
Use macro for 64-bit integer literal suffixes

Some compilers, such as Borland and VS 6, define __int64 instead of the
more standard long long.  Integer literals of type __int64 use the
suffix 'i64' instead of 'll'.  We define the helper macros

  ARCHIVE_LITERAL_LL(n)
  ARCHIVE_LITERAL_ULL(n)

for 'long long' and 'unsigned long long' literals.  The macros use the
proper suffix for the current compiler.

SVN-Revision: 1635

15 years agoConfigure intptr_t and uintptr_t defaults
Brad King [Wed, 11 Nov 2009 14:19:27 +0000 (09:19 -0500)] 
Configure intptr_t and uintptr_t defaults

We define these to 32- or 64-bit signed and unsigned integer types
depending on the pointer size of the target platform.

SVN-Revision: 1634

15 years agoFix wincrypt.h inclusion on VS 6
Brad King [Wed, 11 Nov 2009 14:19:19 +0000 (09:19 -0500)] 
Fix wincrypt.h inclusion on VS 6

The VS 6 version of wincrypt.h only works if _WIN32_WINNT >= 0x0400.
We block its inclusion through windows.h by defining NOCRYPT, and then
define _WIN32_WINNT and include it only when necessary.

SVN-Revision: 1633

15 years agoDefault (u)intmax_t to (u)int64_t
Brad King [Wed, 11 Nov 2009 14:19:14 +0000 (09:19 -0500)] 
Default (u)intmax_t to (u)int64_t

This approach re-uses any work done to choose int64_t and uint64_t to
define defaults for intmax_t and uintmax_t.

SVN-Revision: 1632

15 years agoUse __int64 for int64_t default on Windows
Brad King [Wed, 11 Nov 2009 14:19:08 +0000 (09:19 -0500)] 
Use __int64 for int64_t default on Windows

Many windows compilers define __int64 as a 64-bit type, not just MSVC.

SVN-Revision: 1631

15 years agoUse standard defaults for (u)int32_t and uint16_t
Brad King [Wed, 11 Nov 2009 14:19:02 +0000 (09:19 -0500)] 
Use standard defaults for (u)int32_t and uint16_t

The mapping

  int32_t  -> int
  uint32_t -> unsigned int
  uint16_t -> unsigned short

is valid on many compilers, not just MSVC.

SVN-Revision: 1630

15 years agoProbe for cygwin_conv_path in cmake build, for Cygwin 1.7.
Tim Kientzle [Wed, 11 Nov 2009 07:50:13 +0000 (02:50 -0500)] 
Probe for cygwin_conv_path in cmake build, for Cygwin 1.7.

SVN-Revision: 1629

15 years agoValue stored to 'code' is never read.
Michihiro NAKAJIMA [Mon, 9 Nov 2009 11:06:48 +0000 (06:06 -0500)] 
Value stored to 'code' is never read.

Found by Clang Static Analyzer.

SVN-Revision: 1628

15 years agoValue stored to 'i' is never read.
Michihiro NAKAJIMA [Mon, 9 Nov 2009 11:01:45 +0000 (06:01 -0500)] 
Value stored to 'i' is never read.

Found by Clang Static Analyzer.

SVN-Revision: 1627

15 years agoTeach it to compiler and analyzer that function `lafe_errc' is no return.
Michihiro NAKAJIMA [Mon, 9 Nov 2009 10:56:48 +0000 (05:56 -0500)] 
Teach it to compiler and analyzer that function `lafe_errc' is no return.

Found by Clang Static Analyzer.

SVN-Revision: 1626

15 years agoValue stored to 'i' is never read.
Michihiro NAKAJIMA [Mon, 9 Nov 2009 08:03:27 +0000 (03:03 -0500)] 
Value stored to 'i' is never read.

Found by Clang Static Analyzer.

SVN-Revision: 1625

15 years agoAvoid possibility dereference of null pointer.
Michihiro NAKAJIMA [Mon, 9 Nov 2009 07:58:11 +0000 (02:58 -0500)] 
Avoid possibility dereference of null pointer.

Found by Clang Static Analyzer.

SVN-Revision: 1624

15 years agoAlthough the value stored to 'v' is used in the enclosing expression,
Michihiro NAKAJIMA [Mon, 9 Nov 2009 07:27:38 +0000 (02:27 -0500)] 
Although the value stored to 'v' is used in the enclosing expression,
the value is never actually read from 'v'

Found by Clang Static Analyzer.

SVN-Revision: 1623

15 years agoAlthough the value stored to 'ret2' is used in the enclosing expression,
Michihiro NAKAJIMA [Mon, 9 Nov 2009 07:24:57 +0000 (02:24 -0500)] 
Although the value stored to 'ret2' is used in the enclosing expression,
the value is never actually read from 'ret2'.

Found by Clang Static Analyzer.

SVN-Revision: 1622

15 years agoAlthough the value stored to 'p' is used in the enclosing expression,
Michihiro NAKAJIMA [Mon, 9 Nov 2009 07:21:54 +0000 (02:21 -0500)] 
Although the value stored to 'p' is used in the enclosing expression,
the value is never actually read from 'p'

Found by Clang Static Analyzer.

SVN-Revision: 1621

15 years ago- Value stored to 'data' is never read.
Michihiro NAKAJIMA [Mon, 9 Nov 2009 07:15:09 +0000 (02:15 -0500)] 
- Value stored to 'data' is never read.
- Value stored to 'data_length' is never read.

Found by Clang Static Analyzer.

SVN-Revision: 1620

15 years agoValue stored to 'used' is never read.
Michihiro NAKAJIMA [Mon, 9 Nov 2009 07:06:16 +0000 (02:06 -0500)] 
Value stored to 'used' is never read.

Found by Clang Static Analyzer.

SVN-Revision: 1619

15 years ago- Value stored to 'pax' is never read.
Michihiro NAKAJIMA [Mon, 9 Nov 2009 06:58:12 +0000 (01:58 -0500)] 
- Value stored to 'pax' is never read.
- Value stored to 'p' is never read.
- Value stored to 'd' is never read.

Found by Clang Static Analyzer.

SVN-Revision: 1618

15 years agoValue stored to 's' is never read.
Michihiro NAKAJIMA [Mon, 9 Nov 2009 06:49:03 +0000 (01:49 -0500)] 
Value stored to 's' is never read.

Found by Clang Static Analyzer.

SVN-Revision: 1617

15 years agoReturn ARCHIVE_WARN if large inode number was truncated.
Michihiro NAKAJIMA [Mon, 9 Nov 2009 06:43:09 +0000 (01:43 -0500)] 
Return ARCHIVE_WARN if large inode number was truncated.

Found by Clang Static Analyzer.

SVN-Revision: 1616

15 years ago- Value stored to 'ret' is never read.
Michihiro NAKAJIMA [Mon, 9 Nov 2009 06:13:29 +0000 (01:13 -0500)] 
- Value stored to 'ret' is never read.
- Value stored to 'cpio' is never read.
- Although the value stored to 'v' is used in the enclosing expression,
  the value is never actually read from 'v'.

Found by Clang Static Analyzer.

SVN-Revision: 1615

15 years agopkgconfig support from Xavier, plus a couple of missing files added to
Tim Kientzle [Mon, 9 Nov 2009 05:34:56 +0000 (00:34 -0500)] 
pkgconfig support from Xavier, plus a couple of missing files added to
the distfile generation.

SVN-Revision: 1614

15 years agoIf you overflow an int64_t, use INT64_MAX, not UINT64_MAX.
Tim Kientzle [Sun, 8 Nov 2009 22:28:50 +0000 (17:28 -0500)] 
If you overflow an int64_t, use INT64_MAX, not UINT64_MAX.

SVN-Revision: 1613

15 years agoValue stored to 'cpio' is never read.
Michihiro NAKAJIMA [Sun, 8 Nov 2009 20:20:16 +0000 (15:20 -0500)] 
Value stored to 'cpio' is never read.

Found by Clang Static Analyzer.

SVN-Revision: 1612

15 years agoValue stored to 'ret' is never read.
Michihiro NAKAJIMA [Sun, 8 Nov 2009 20:15:34 +0000 (15:15 -0500)] 
Value stored to 'ret' is never read.

Found by Clang Static Analyzer.

SVN-Revision: 1611

15 years agoValue stored to 'target_block_length' is never read.
Michihiro NAKAJIMA [Sun, 8 Nov 2009 20:12:17 +0000 (15:12 -0500)] 
Value stored to 'target_block_length' is never read.

Found by Clang Static Analyzer.

SVN-Revision: 1610

15 years agoValue stored to 'state' is never read.
Michihiro NAKAJIMA [Sun, 8 Nov 2009 20:09:50 +0000 (15:09 -0500)] 
Value stored to 'state' is never read.

Found by Clang Static Analyzer.

SVN-Revision: 1609

15 years agoValue stored to 'target_block_length' is never read.
Michihiro NAKAJIMA [Sun, 8 Nov 2009 20:04:27 +0000 (15:04 -0500)] 
Value stored to 'target_block_length' is never read.

Found by Clang Static Analyzer.

SVN-Revision: 1608

15 years ago- Value stored to 'ret' is never read.
Michihiro NAKAJIMA [Sun, 8 Nov 2009 20:01:27 +0000 (15:01 -0500)] 
- Value stored to 'ret' is never read.
- Value stored to 'bits' is never read.

Found by Clang Static Analyzer.

SVN-Revision: 1607

15 years agoValue stored to 'target_block_length' is never read.
Michihiro NAKAJIMA [Sun, 8 Nov 2009 19:54:20 +0000 (14:54 -0500)] 
Value stored to 'target_block_length' is never read.

Found by Clang Static Analyzer.

SVN-Revision: 1606

15 years agoValue stored to 'r' is never read.
Michihiro NAKAJIMA [Sun, 8 Nov 2009 19:50:29 +0000 (14:50 -0500)] 
Value stored to 'r' is never read.

Found by Clang Static Analyzer.

SVN-Revision: 1605

15 years agoValue stored to 'ret' is never read.
Michihiro NAKAJIMA [Sun, 8 Nov 2009 19:47:28 +0000 (14:47 -0500)] 
Value stored to 'ret' is never read.

Found by Clang Static Analyzer.

SVN-Revision: 1604

15 years ago- Value stored to 'err' is never read.
Michihiro NAKAJIMA [Sun, 8 Nov 2009 19:41:53 +0000 (14:41 -0500)] 
- Value stored to 'err' is never read.
- Value stored to 'dest' is never read.

Found by Clang Static Analyzer.

SVN-Revision: 1603

15 years ago- Value stored to 'line' is never read.
Michihiro NAKAJIMA [Sun, 8 Nov 2009 19:36:57 +0000 (14:36 -0500)] 
- Value stored to 'line' is never read.
- Value stored to 'h' is never read.
- Value stored to 'old_entry' during its initialization is never read.
- Value stored to 'dest' is never read.

Found by Clang Static Analyzer.

SVN-Revision: 1602

15 years agoValue stored to 'r' is never read.
Michihiro NAKAJIMA [Sun, 8 Nov 2009 19:24:12 +0000 (14:24 -0500)] 
Value stored to 'r' is never read.

Found by Clang Static Analyzer.

SVN-Revision: 1601

15 years agoValue stored to 'ar' is never read.
Michihiro NAKAJIMA [Sun, 8 Nov 2009 19:18:54 +0000 (14:18 -0500)] 
Value stored to 'ar' is never read.

Found by Clang Static Analyzer.

SVN-Revision: 1600

15 years agoValue stored to 'l' is never read.
Michihiro NAKAJIMA [Sun, 8 Nov 2009 19:15:11 +0000 (14:15 -0500)] 
Value stored to 'l' is never read.

Found by Clang Static Analyzer.

SVN-Revision: 1599

15 years agoValue stored to 'read_avail' is never read.
Michihiro NAKAJIMA [Sun, 8 Nov 2009 19:09:20 +0000 (14:09 -0500)] 
Value stored to 'read_avail' is never read.

Found by Clang Static Analyzer.

SVN-Revision: 1598

15 years agoReturn ARCHIVE_FATAL if BZ2_bzDecompressEnd failed.
Michihiro NAKAJIMA [Sun, 8 Nov 2009 19:06:43 +0000 (14:06 -0500)] 
Return ARCHIVE_FATAL if BZ2_bzDecompressEnd failed.

Found by Clang Static Analyzer.

SVN-Revision: 1597

15 years ago- Value stored to 'filter' is never read.
Michihiro NAKAJIMA [Sun, 8 Nov 2009 19:00:01 +0000 (14:00 -0500)] 
- Value stored to 'filter' is never read.
- Value stored to 'dummy_buffer' is never read.

Found by Clang Static Analyzer.

SVN-Revision: 1596

15 years agoValue stored to 'target_block_length' is never read.
Michihiro NAKAJIMA [Sun, 8 Nov 2009 18:47:56 +0000 (13:47 -0500)] 
Value stored to 'target_block_length' is never read.

Found by Clang Static Analyzer.

SVN-Revision: 1595

15 years agoReturn ARCHIVE_WARN properly if large inode number was truncated.
Michihiro NAKAJIMA [Sun, 8 Nov 2009 18:36:26 +0000 (13:36 -0500)] 
Return ARCHIVE_WARN properly if large inode number was truncated.

Found by Clang Static Analyzer.

SVN-Revision: 1594

15 years agoRemove duplicate code.
Michihiro NAKAJIMA [Sun, 8 Nov 2009 11:52:49 +0000 (06:52 -0500)] 
Remove duplicate code.

SVN-Revision: 1593

15 years agoIt is better that all of functions of checking volume descriptor
Michihiro NAKAJIMA [Sun, 8 Nov 2009 10:44:57 +0000 (05:44 -0500)] 
It is better that all of functions of checking volume descriptor
have the same interface.

SVN-Revision: 1592

15 years agoIf a volume description is found, do not try checking of another
Michihiro NAKAJIMA [Sun, 8 Nov 2009 10:23:59 +0000 (05:23 -0500)] 
If a volume description is found, do not try checking of another
volume description.

SVN-Revision: 1591

15 years agoThanks to Xavier for pointing out that the security.capability xattr
Tim Kientzle [Sun, 8 Nov 2009 07:06:02 +0000 (02:06 -0500)] 
Thanks to Xavier for pointing out that the security.capability xattr
on Linux must be restored last.  Let's try moving xattr restore to
after file data and see if that works any better; we may end up having
to do a full xattr restore both before and after the file data.

This also changes the behavior of xattr restore failures; they now
cause warnings when the entry is finished (which can be as late as
archive_write_close()) rather than when the header is written.

SVN-Revision: 1590

15 years agoBe a little more careful about identifying mdoc-format manpages.
Tim Kientzle [Sun, 8 Nov 2009 02:33:34 +0000 (21:33 -0500)] 
Be a little more careful about identifying mdoc-format manpages.
In particular, I recently had the update script pick up and try
to convert libarchive.so.5. Ouch.

SVN-Revision: 1589

15 years agoFix a couple of markup errors and clarify the discussion of miscellaneous
Tim Kientzle [Sun, 8 Nov 2009 02:32:03 +0000 (21:32 -0500)] 
Fix a couple of markup errors and clarify the discussion of miscellaneous
tar extensions.

SVN-Revision: 1588

15 years agoMake the CTest integration simpler and a little more robust
Tim Kientzle [Sat, 7 Nov 2009 23:35:18 +0000 (18:35 -0500)] 
Make the CTest integration simpler and a little more robust
by just reading list.h directly into cmake.  This only requires
a suitable "DEFINE_TEST" macro.

SVN-Revision: 1587

15 years agoCDash support, thanks to Brad King.
Tim Kientzle [Sat, 7 Nov 2009 23:08:41 +0000 (18:08 -0500)] 
CDash support, thanks to Brad King.

SVN-Revision: 1586

15 years agoMinGW defines a value of S_IFBLK which is both useless and wrong.
Tim Kientzle [Sat, 7 Nov 2009 07:31:15 +0000 (02:31 -0500)] 
MinGW defines a value of S_IFBLK which is both useless and wrong.
Comment out this sanity-check on MinGW.  (It already doesn't apply
to VC++ because Microsoft doesn't define S_IFBLK.)

test_entry sanity-checks that S_IFBLK has the expected value on every
platform, even though libarchive per se doesn't depend on this.  So far,
MinGW is the only platform that's ever broken one of these checks, which
is reassuring, since it means that clients can reasonably pass unaltered
st_mode values into libarchive.  Even on MinGW, it will work, since
MinGW can never actually set S_IFBLK (Windows filesystems don't support it).

SVN-Revision: 1585

16 years agoImprove detecting LZMA stream data.
Michihiro NAKAJIMA [Fri, 6 Nov 2009 15:16:19 +0000 (10:16 -0500)] 
Improve detecting LZMA stream data.
- Checking of the first byte of LZMA stream.
  * lzma of XZ Utils with option -e records 0x5d in the first byte.
  * It is possible that lzma of LZMA SDK records various data in the
    first byte.
- Checking of second and third bytes of LZMA stream.
  * lzma of LZMA SDK with option -d12,-d13,-d14 and -d15 records
    0x1000,0x2000,0x4000 and 0x8000 in second through fifth bytes
    of LZMA stream. It means second and third bytes are not always
    zero.
- Checking of sixth through fourteenth bytes of LZMA stream.
  * This bytes are recorded uncompressed size and lzma of XZ Utils
    always records -1 in this field.

SVN-Revision: 1584

16 years agoadd support for setting timestamps with ns resolution. utimensat and
Björn Jacke [Fri, 6 Nov 2009 11:42:45 +0000 (06:42 -0500)] 
add support for setting timestamps with ns resolution. utimensat and
futimens are defined in POSIX.1-2008. They are available on Linux since
glibc 2.6 and kernel 2.6.22.

SVN-Revision: 1583

16 years agoCast away a minor type mismatch.
Tim Kientzle [Fri, 6 Nov 2009 06:04:21 +0000 (01:04 -0500)] 
Cast away a minor type mismatch.

SVN-Revision: 1582

16 years agoAdd some tests for LZMA as other compression.
Michihiro NAKAJIMA [Thu, 5 Nov 2009 12:01:48 +0000 (07:01 -0500)] 
Add some tests for LZMA as other compression.

SVN-Revision: 1581

16 years agoWhitespace fix.
Tim Kientzle [Thu, 5 Nov 2009 05:44:42 +0000 (00:44 -0500)] 
Whitespace fix.

SVN-Revision: 1580

16 years agoCompression of test data for ISO reader switch from bzip2/gz to compress
Michihiro NAKAJIMA [Mon, 2 Nov 2009 06:48:54 +0000 (01:48 -0500)] 
Compression of test data for ISO reader switch from bzip2/gz to compress
so that all of ISO reader tests can be worked on every platform.

SVN-Revision: 1579

16 years agoRename LOCALE_DE to LOCALE_UTF8, since the code assumes it's a UTF8 locale. Set...
Tim Kientzle [Mon, 2 Nov 2009 04:39:11 +0000 (23:39 -0500)] 
Rename LOCALE_DE to LOCALE_UTF8, since the code assumes it's a UTF8 locale.  Set it to NULL on Windows, change some of the tests to skip when this is NULL.  This removes most of the assertion failures in test_entry.

SVN-Revision: 1578

16 years agoInclude needsAscent on the initial stack entry so that we correctly chdir() back...
Tim Kientzle [Mon, 2 Nov 2009 04:37:25 +0000 (23:37 -0500)] 
Include needsAscent on the initial stack entry so that we correctly chdir() back to our starting directory when the traversal is complete.

On Windows, handle wildcard setup in tree_open().

SVN-Revision: 1577

16 years agoRevert from previous change of tar/tree.c. It's my local hack.
Michihiro NAKAJIMA [Mon, 2 Nov 2009 03:04:10 +0000 (22:04 -0500)] 
Revert from previous change of tar/tree.c. It's my local hack.

SVN-Revision: 1576

16 years agoTo be robust when ISO image is broken.
Michihiro NAKAJIMA [Mon, 2 Nov 2009 02:59:56 +0000 (21:59 -0500)] 
To be robust when ISO image is broken.

SVN-Revision: 1575

16 years agoUse CP_ACP instead of CP_THREAD_ACP.
Tim Kientzle [Mon, 2 Nov 2009 02:42:21 +0000 (21:42 -0500)] 
Use CP_ACP instead of CP_THREAD_ACP.

SVN-Revision: 1574

16 years agoFuzz the mtree reader: Extract the sample file and add it to the list of fuzz-test...
Tim Kientzle [Sun, 1 Nov 2009 22:27:45 +0000 (17:27 -0500)] 
Fuzz the mtree reader: Extract the sample file and add it to the list of fuzz-test inputs.

SVN-Revision: 1573

16 years agoFix the name of one of the distfiles.
Tim Kientzle [Sun, 1 Nov 2009 21:51:33 +0000 (16:51 -0500)] 
Fix the name of one of the distfiles.

SVN-Revision: 1572

16 years agoExtend the fuzz tester:
Tim Kientzle [Sun, 1 Nov 2009 21:49:53 +0000 (16:49 -0500)] 
Extend the fuzz tester:
 * Test gzip reader
 * Test xz reader
 * Test cpio_bin format

SVN-Revision: 1571

16 years agoExtend the fuzz tester:
Tim Kientzle [Sun, 1 Nov 2009 21:46:24 +0000 (16:46 -0500)] 
Extend the fuzz tester:
 * Compress test_fuzz_1.iso so we can save space in source control and so we can fuzz a compressed file.
 * Extract the "ar" sample file so we can use it in the fuzz tester.

SVN-Revision: 1570

16 years agoUse the format_raw handler to decompress files before trying to
Tim Kientzle [Sun, 1 Nov 2009 18:07:03 +0000 (13:07 -0500)] 
Use the format_raw handler to decompress files before trying to
fuzz them.  This will allow us to re-use more of the ISO sample files,
for instance.

SVN-Revision: 1569

16 years ago-vvv should be full verbosity just like -vv.
Tim Kientzle [Sun, 1 Nov 2009 18:05:18 +0000 (13:05 -0500)] 
-vvv should be full verbosity just like -vv.

SVN-Revision: 1568

16 years agoDo not reject a directory entry which couldn't find the original place of
Michihiro NAKAJIMA [Sun, 1 Nov 2009 08:47:46 +0000 (03:47 -0500)] 
Do not reject a directory entry which couldn't find the original place of
itself.

SVN-Revision: 1567

16 years agoThe file queue which has "CL" extension(called cl_files) must use its
Michihiro NAKAJIMA [Sun, 1 Nov 2009 07:46:57 +0000 (02:46 -0500)] 
The file queue which has "CL" extension(called cl_files) must use its
cl_offset(which indicates a offset of the relocated directory entry)
for heap key. The function relocate_dir()'s algorithm expects cl_files
in order of cl_offset.

SVN-Revision: 1566

16 years agoMake the __FBSDID() handling more platform-agnostic by using
Tim Kientzle [Sun, 1 Nov 2009 06:56:20 +0000 (01:56 -0500)] 
Make the __FBSDID() handling more platform-agnostic by using
HAVE_SYS_CDEFS_H to control the inclusion of sys/cdefs.h and
defining a fake __FBSDID() macro if we need one.  In particular,
this deals a lot more gracefully with systems that are not
FreeBSD but use FreeBSD-derived system headers.

See Issue 46 on libarchive.googlecode.com for discussion.
Submitted by: cpr420

SVN-Revision: 1565

16 years agoWhitespace fix.
Tim Kientzle [Sun, 1 Nov 2009 06:48:39 +0000 (01:48 -0500)] 
Whitespace fix.

SVN-Revision: 1564

16 years agoAvoid %j and uintmax in cpio.
Tim Kientzle [Sun, 1 Nov 2009 02:36:25 +0000 (22:36 -0400)] 
Avoid %j and uintmax in cpio.

SVN-Revision: 1563

16 years agoTrying to figure out what printf modifiers to use on what platforms to
Tim Kientzle [Sun, 1 Nov 2009 02:14:14 +0000 (22:14 -0400)] 
Trying to figure out what printf modifiers to use on what platforms to
display 64-bit values is getting to be  real PITA.  Just roll our
own conversion and use that.

SVN-Revision: 1562

16 years agoGet int64_t on Haiku.
Tim Kientzle [Sat, 31 Oct 2009 22:47:51 +0000 (18:47 -0400)] 
Get int64_t on Haiku.

SVN-Revision: 1561

16 years agoBe a little more selective when verifying mode values. In particular,
Tim Kientzle [Sat, 31 Oct 2009 22:45:33 +0000 (18:45 -0400)] 
Be a little more selective when verifying mode values.  In particular,
ignore extra high-order bits that are added by Haiku's BFS filesystem.

SVN-Revision: 1560

16 years agoWindows build fix.
Tim Kientzle [Sat, 31 Oct 2009 20:03:25 +0000 (16:03 -0400)] 
Windows build fix.

SVN-Revision: 1559

16 years agoarchive_entry_copy_bhfi should only be built on Windows.
Tim Kientzle [Sat, 31 Oct 2009 19:24:09 +0000 (15:24 -0400)] 
archive_entry_copy_bhfi should only be built on Windows.

SVN-Revision: 1558

16 years agoFix some compiler warnings: Mostly just removing unused parameters.
Tim Kientzle [Sat, 31 Oct 2009 17:35:00 +0000 (13:35 -0400)] 
Fix some compiler warnings: Mostly just removing unused parameters.

SVN-Revision: 1557

16 years agoSkip hardlink checks on Haiku, remove some ancient hacks to get
Tim Kientzle [Sat, 31 Oct 2009 17:19:37 +0000 (13:19 -0400)] 
Skip hardlink checks on Haiku, remove some ancient hacks to get
libarchive_test to work against libarchive pre-1.9.

SVN-Revision: 1556

16 years agoSkip the root uname test on both Cygwin and Haiku (neither of which has
Tim Kientzle [Sat, 31 Oct 2009 17:18:31 +0000 (13:18 -0400)] 
Skip the root uname test on both Cygwin and Haiku (neither of which has
predictable usernames for UID 0, so this test doesn't work on either one).

SVN-Revision: 1555

16 years agoTweak for Haiku.
Tim Kientzle [Sat, 31 Oct 2009 17:17:14 +0000 (13:17 -0400)] 
Tweak for Haiku.

SVN-Revision: 1554

16 years agoShuffle the major/minor/makedev support a bit; this should work
Tim Kientzle [Sat, 31 Oct 2009 17:16:37 +0000 (13:16 -0400)] 
Shuffle the major/minor/makedev support a bit; this should work
on both Windows and Haiku.

SVN-Revision: 1553

16 years agoSynchronize the test harnesses and force atime tests to always pass
Tim Kientzle [Sat, 31 Oct 2009 17:14:50 +0000 (13:14 -0400)] 
Synchronize the test harnesses and force atime tests to always pass
on Haiku (which doesn't support atime).

SVN-Revision: 1552

16 years agoAdd extra text before the uuencoded data.
Michihiro NAKAJIMA [Sat, 31 Oct 2009 05:37:10 +0000 (01:37 -0400)] 
Add extra text before the uuencoded data.

SVN-Revision: 1551

16 years agoBug fix. Bidding failed when a character of the end of buffer which
Michihiro NAKAJIMA [Sat, 31 Oct 2009 05:03:48 +0000 (01:03 -0400)] 
Bug fix. Bidding failed when a character of the end of buffer which
was checked for bidding was '\n' but not the end of file.

SVN-Revision: 1550

16 years agoImprove directory order; make sure a directory entry is exposed
Michihiro NAKAJIMA [Sat, 31 Oct 2009 03:13:50 +0000 (23:13 -0400)] 
Improve directory order; make sure a directory entry is exposed
after its parent especially sub directories under the rr_moved
directory.

SVN-Revision: 1549

16 years agoFix a bug; use relevant function for reading create time.
Michihiro NAKAJIMA [Fri, 30 Oct 2009 12:22:36 +0000 (08:22 -0400)] 
Fix a bug; use relevant function for reading create time.

SVN-Revision: 1548

16 years agoAdd a test uudecode filter decodes a data of the Base64 encoding.
Michihiro NAKAJIMA [Fri, 30 Oct 2009 10:46:33 +0000 (06:46 -0400)] 
Add a test uudecode filter decodes a data of the Base64 encoding.

SVN-Revision: 1547

16 years agoMake sure a line is fully read before checking it for bidding
Michihiro NAKAJIMA [Fri, 30 Oct 2009 10:31:07 +0000 (06:31 -0400)] 
Make sure a line is fully read before checking it for bidding
for uudecode.

SVN-Revision: 1546

16 years agoMake sure uudecode filter handles lines which are broken
Michihiro NAKAJIMA [Fri, 30 Oct 2009 06:57:36 +0000 (02:57 -0400)] 
Make sure uudecode filter handles lines which are broken
across multiple reads.

Suggested by Tim.

SVN-Revision: 1545

16 years agoMore sanity check for ISO 9660.
Michihiro NAKAJIMA [Thu, 22 Oct 2009 06:05:57 +0000 (02:05 -0400)] 
More sanity check for ISO 9660.
Add check for Enhanced Volume Descriptor and other Supplementary Volume
Descriptor.

SVN-Revision: 1543

16 years agoAdd uudecode filter.
Michihiro NAKAJIMA [Tue, 20 Oct 2009 06:16:28 +0000 (02:16 -0400)] 
Add uudecode filter.

SVN-Revision: 1542

16 years agoSet return parameters.
Michihiro NAKAJIMA [Sun, 18 Oct 2009 05:31:20 +0000 (01:31 -0400)] 
Set return parameters.

SVN-Revision: 1541