100 Commits
Author SHA1 Message Date
Joerg Sonnenberger 5c94defed4 More mode_t fallout from Solaris
SVN-Revision: 3920
2011-12-13 19:24:48 -05:00
Joerg Sonnenberger 57418cb005 Cast explicit to u_int to appeace gcc
SVN-Revision: 3919
2011-12-13 19:14:13 -05:00
Joerg Sonnenberger 95c74682bd Properly check if EXT2_IOC_GETFLAGS is actually usable.
OpenIndiana likes to install e2fsprogs, but doesn't provide a working
ioctl.

SVN-Revision: 3918
2011-12-13 18:07:17 -05:00
Joerg Sonnenberger 88d19ea444 Adjust cut-off condition to correctly return INT_MAX for large integers.
Found by Maksymilian Arciemowicz <cxib@securityreason.com>.

SVN-Revision: 2810
2010-12-04 19:54:03 -05:00
Joerg Sonnenberger e96068eed1 Fix typo
SVN-Revision: 2534
2010-07-15 11:00:37 -04:00
Joerg Sonnenberger 5316aa647a Reflect various merges for 2.8.4.
SVN-Revision: 2519
2010-06-30 05:56:17 -04:00
Joerg Sonnenberger 040d67b120 Merge r2511:
Add two more cases where wcscmp is needed. From Hauke Fath

SVN-Revision: 2512
2010-06-28 17:44:02 -04:00
Joerg Sonnenberger f106ec929f Add two more cases where wcscmp is needed. From Hauke Fath
SVN-Revision: 2511
2010-06-28 17:31:24 -04:00
Joerg Sonnenberger 6530417dad Merge r2498:
Improve support for systems without modern wctype.h by providing local
versions of wcscpy in test_entry.c and wcscmp in main.c.

SVN-Revision: 2510
2010-06-27 14:51:04 -04:00
Joerg Sonnenberger 86eb88d73e Improve support for systems without modern wctype.h by providing local
versions of wcscpy in test_entry.c and wcscmp in main.c.

SVN-Revision: 2498
2010-06-24 16:14:41 -04:00
Joerg Sonnenberger e44e110b47 Merge r2495: Fix distribution list to include all cpio testcases.
Megre r2496: Don't compile in wide char test cases if wcscpy is missing.

SVN-Revision: 2497
2010-06-21 11:27:51 -04:00
Joerg Sonnenberger 91e90752a7 Don't compile in wide char test cases if wcscpy is missing.
SVN-Revision: 2496
2010-06-21 08:42:02 -04:00
Joerg Sonnenberger e8b514242a Fix distribution list to include all cpio testcases.
SVN-Revision: 2495
2010-06-21 08:31:42 -04:00
Joerg Sonnenberger 8256cd6d65 Merge 2493:
Be nice to ancient bzlib.h, it needs stdio.h.

SVN-Revision: 2494
2010-06-20 17:24:22 -04:00
Joerg Sonnenberger 5cdf3d1568 Be nice to ancient bzlib.h, it needs stdio.h.
SVN-Revision: 2493
2010-06-20 17:22:40 -04:00
Joerg Sonnenberger 7649d2326f Merge r2490 and r2491:
Fall back to getgrgid and getpwuid if the reentrant versions are missing.

SVN-Revision: 2492
2010-06-19 13:47:04 -04:00
Joerg Sonnenberger b44e4c8ab6 Must define constants to 1 for #if to work.
SVN-Revision: 2491
2010-06-19 13:34:15 -04:00
Joerg Sonnenberger 2730e1cb1d Fall back to getgrgid and getpwuid if the reentrant versions are missing.
SVN-Revision: 2490
2010-06-19 13:25:58 -04:00
Joerg Sonnenberger d13fa6d39e Merge 2488: Deal with bzip2 before 1.0 by not using it.
SVN-Revision: 2489
2010-06-19 09:14:17 -04:00
Joerg Sonnenberger 3a5fce6927 Deal with bzip2 before 1.0 by not using it.
SVN-Revision: 2488
2010-06-19 09:02:48 -04:00
Joerg Sonnenberger c90bba04d4 Merge 2482: stdint.h is needed on QNX for the test cases too.
SVN-Revision: 2483
2010-06-17 10:41:44 -04:00
Joerg Sonnenberger c255f11d38 QNX needs stdint.h in the test cases as well.
From Sean Boudreau.

SVN-Revision: 2482
2010-06-17 10:40:05 -04:00
Joerg Sonnenberger 2b10e8378c Merge r2480:
If no equal sign was found in the buffer, don't use it as base for
computing the line length.

SVN-Revision: 2481
2010-06-16 17:55:50 -04:00
Joerg Sonnenberger 7476f48f19 If no equal sign was found in the buffer, don't use it as base for
computing the line length.

SVN-Revision: 2480
2010-06-16 17:49:51 -04:00
Joerg Sonnenberger 549ae1d50a Merge r2269 and part of r2359:
Only enable FreeBSD-style xattr support, if EXTATTR_NAMESPACE_USER
exists.

SVN-Revision: 2479
2010-06-16 16:29:53 -04:00
Joerg Sonnenberger 592c18804d Merged r2058, r2366, r2375-r2380, r2385-r2392, r2395, r2402,r
r2404-r2405, r2410-r2412, r2415, r2420, r2476 from trunk:

- Refactor hash function scan to use a compile+link test to increase
  robustness
- Deal with missing getgrnam_r / getpwnam_r functions
- Properly define HAVE_SIGACTION for cmake
- Only use poll in filter_fork.c, if either poll.h or sys/poll.h exists
- \\ -> \e in man pages, drop empty BUGS section
- Deal with interrupted reads and continue

Bump version to 2.8.4

SVN-Revision: 2478
2010-06-16 16:05:39 -04:00
Joerg Sonnenberger 77cfbb9825 Revert r2412 and require autoconf 2.65 instead.
SVN-Revision: 2477
2010-06-16 14:38:50 -04:00
Joerg Sonnenberger b2880eecfb Only use poll(2) if either poll.h or sys/poll.h exists.
SVN-Revision: 2476
2010-06-15 19:55:05 -04:00
Joerg Sonnenberger 426531d609 No empty BUGS section. It's not like they don't exist...
SVN-Revision: 2392
2010-05-13 17:44:23 -04:00
Joerg Sonnenberger 2237969990 \\ -> \e
SVN-Revision: 2391
2010-05-13 17:38:34 -04:00
Joerg Sonnenberger 2ce66f4b1c Rewrite the hash function detection. Build an actual test program using
archive_hash.h and link against libcrypto if needed.

Fixes issue #73 and #86.

SVN-Revision: 2375
2010-05-09 19:48:04 -04:00
Joerg Sonnenberger 12c8034366 Fix archive_rb_iterate for the min/max case.
SVN-Revision: 2345
2010-04-30 09:59:24 -04:00
Joerg Sonnenberger e98017f6a6 Use custom include guard
SVN-Revision: 2342
2010-04-29 01:32:43 -04:00
Joerg Sonnenberger 7468944876 Hook up archive_rb.[ch] to the build.
SVN-Revision: 2336
2010-04-28 14:16:39 -04:00
Joerg Sonnenberger 8c8a617a89 Port NetBSD's rb.c. Changes here are:
- Use archive_ prefix for types and __archive_ prefix for the functions 
  to avoid conflicts with system headers.
- No debug code, statistics and only the "small" code.
- No stdbool.h.

The only real assumption is that pointers have 4 bytes alignment.

SVN-Revision: 2335
2010-04-28 14:05:20 -04:00
Joerg Sonnenberger b96757402a Make sure that fd has a valid value.
SVN-Revision: 2316
2010-04-26 16:26:40 -04:00
Joerg Sonnenberger 9a51f5cea2 Merge r2250:
Reorder sections to canonical order. Escape backslashes.

SVN-Revision: 2270
2010-04-23 16:37:10 -04:00
Joerg Sonnenberger 6d23f1c569 Only include the FreeBSD-style extended attribute support, if
EXTATTR_NAMESPACE_USER is defined. It is missing on FreeBSD 4 and
DragonFly. Reported by Antonio Huete Jimenez as NetBSD's pkg/43175.

SVN-Revision: 2269
2010-04-19 18:27:50 -04:00
Joerg Sonnenberger 5e8e019bb1 Reorder sections to canonical order. Escape backslashes.
SVN-Revision: 2250
2010-04-12 15:06:51 -04:00
Joerg Sonnenberger 9aa052b357 Reorder sections to canonical order.
SVN-Revision: 2249
2010-04-12 15:06:23 -04:00
Joerg Sonnenberger d45151bf13 getgrnam_r and getpwnam_r might not exist, so fallback to the older
non-reentrant getgrnam and getpwnam in that case. Based on patch
from Hauke Fath.

SVN-Revision: 2058
2010-03-31 09:56:55 -04:00
Joerg Sonnenberger e6988a6a21 Sort arguments for calloc. Add comments about power-of-two check
SVN-Revision: 2057
2010-03-30 11:30:01 -04:00
Joerg Sonnenberger 988df1e6e0 Explicit test archive_read_next_header against ARCHIVE_OK
SVN-Revision: 2056
2010-03-26 11:42:15 -04:00
Joerg Sonnenberger 210f1882db Use unsigned int for the link count to be consistent with archive_entry.
Compute hashes and buckets using size_t. Be consistent in the sparse
freeing.

SVN-Revision: 2055
2010-03-24 13:52:30 -04:00
Joerg Sonnenberger e72445f8ab res->buckets is always !NULL, so drop checks for it.
SVN-Revision: 2054
2010-03-24 13:09:59 -04:00
Joerg Sonnenberger 9c9e9a4f2a - Use calloc instead of malloc + zeroing
- Enforce power-of-two size and use bitops instead of %

SVN-Revision: 2053
2010-03-24 12:44:36 -04:00
Joerg Sonnenberger ecefaacc8d Only run make maintainer-clean etc, if the Makefile actually exists.
SVN-Revision: 2052
2010-03-24 12:43:52 -04:00
Joerg Sonnenberger 6c32709a2f Fix typo.
SVN-Revision: 2034
2010-03-14 13:55:20 -04:00
Joerg Sonnenberger 431bbfd673 libarchive 2.8.1
SVN-Revision: 2033
2010-03-13 20:59:09 -05:00
Joerg Sonnenberger ea0b888e90 Merge revision 2031: Use groff -mdoc2html
SVN-Revision: 2032
2010-03-13 20:38:19 -05:00
Joerg Sonnenberger 008335add5 Use mdoc2html, -T html doesn't work at least with the groff 1.19.2 in
NetBSD.

XXX This should most likely use mandoc for the HTML output

SVN-Revision: 2031
2010-03-13 20:36:15 -05:00
Joerg Sonnenberger 14413320e7 Merge r1940:
Improve detection of SHA2 functions in OpenSSL to deal with ancient
versions like in Mac OS X and FreeBSD 6.x. Fixes #65 and should fix #55.

SVN-Revision: 2024
2010-03-07 13:25:29 -05:00
Joerg Sonnenberger 55f174cf4c Merge r1922:
The second argument for lafe_line_reader has been changed to a boolean
in revision 1385, catch up.

SVN-Revision: 2023
2010-03-07 13:23:57 -05:00
Joerg Sonnenberger e3ee27b437 Merge r1917:
Do not leak setup_xattr into the global name space.

SVN-Revision: 2022
2010-03-07 13:22:11 -05:00
Joerg Sonnenberger 5cd1e030b1 Sort out the remaining format string vs argument types mismatches.
SVN-Revision: 1988
2010-02-25 11:16:36 -05:00
Joerg Sonnenberger ac8ba3fa05 Add __LA_PRINTF to enable format-string checks for GCC.
SVN-Revision: 1987
2010-02-25 11:13:05 -05:00
Joerg Sonnenberger cdaedd75bd Support z for (s)size_t.
SVN-Revision: 1986
2010-02-25 10:54:03 -05:00
Joerg Sonnenberger 99c02b032e Add missing argument for archive_set_error to match format string.
SVN-Revision: 1985
2010-02-25 10:49:41 -05:00
Joerg Sonnenberger cdc2c15a74 Fix some types for printf-like functions.
SVN-Revision: 1984
2010-02-25 10:48:06 -05:00
Joerg Sonnenberger 7cf625f3e1 Be consistent and complete and document all available options.
Fix markup for long options.

SVN-Revision: 1964
2010-02-22 18:28:06 -05:00
Joerg Sonnenberger 31c87d90f5 Document the various long options and use consistent markup.
SVN-Revision: 1963
2010-02-22 15:31:21 -05:00
Joerg Sonnenberger fe76f7e43f Fix a typo. Annotate that archive_entry_mode is the equivalent of
st_mode.

SVN-Revision: 1962
2010-02-22 12:54:43 -05:00
Joerg Sonnenberger 926b42bb89 archive_entry_set_XXX is an alias for archive_entry_copy_XXX.
SVN-Revision: 1961
2010-02-22 09:08:05 -05:00
Joerg Sonnenberger d64586c52a Reduce to the basic creation/destroy functions and an overview over the
accessor functions. Reference the man page groups for the details.

SVN-Revision: 1960
2010-02-21 23:12:35 -05:00
Joerg Sonnenberger 01a67813a6 Add description of archive_entry_perm/archive_entry_set_perm and
the interaction with archive_entry_set_mode. Move the description of
the latter to archive_entry_stat.3, where archive_entry_filetype and co
are.

SVN-Revision: 1959
2010-02-21 23:11:58 -05:00
Joerg Sonnenberger c13da1af14 Hook up the remaining man pages.
SVN-Revision: 1958
2010-02-21 23:00:13 -05:00
Joerg Sonnenberger d92d201268 The majority of the stat(2) like interface.
SVN-Revision: 1957
2010-02-21 22:58:12 -05:00
Joerg Sonnenberger 06ddccbacf Simplify birthtime handling and ensure that it is unset if the platform
doesn't support it.

SVN-Revision: 1956
2010-02-21 22:24:33 -05:00
Joerg Sonnenberger 3a44b6b2f6 Add archive_entry_strmode. Spaces around em-dash.
SVN-Revision: 1953
2010-02-21 20:55:42 -05:00
Joerg Sonnenberger 365123bf0f Split functions related to Unix permission model from archive_entry(3).
SVN-Revision: 1952
2010-02-21 20:21:53 -05:00
Joerg Sonnenberger 3cf2e0c40c Mention difference between _set and _copy.
SVN-Revision: 1950
2010-02-21 20:14:20 -05:00
Joerg Sonnenberger 09eb6be6a8 Man page for the path name related functions.
SVN-Revision: 1946
2010-02-21 18:21:12 -05:00
Joerg Sonnenberger 832c071038 Kill a trailing comma at the end of the .Nm list.
SVN-Revision: 1941
2010-02-21 12:46:41 -05:00
Joerg Sonnenberger 6d54e6994e Improve detection of SHA2 functions in OpenSSL to deal with ancient
versions like in Mac OS X and FreeBSD 6.x. Fixes #65 and should fix #55.

SVN-Revision: 1940
2010-02-21 09:23:09 -05:00
Joerg Sonnenberger 4f8441833f Install archive_entry_acl.3 and archive_entry_time.3.
SVN-Revision: 1939
2010-02-21 09:14:04 -05:00
Joerg Sonnenberger 4491e6dc32 Fix the description of ctime as noticed by Tim.
SVN-Revision: 1938
2010-02-21 09:04:51 -05:00
Joerg Sonnenberger 9fe484347c mdoclint.
SVN-Revision: 1934
2010-02-20 21:33:20 -05:00
Joerg Sonnenberger 2e7d77b572 First draft of a man page for the ACL functions.
SVN-Revision: 1933
2010-02-20 21:27:38 -05:00
Joerg Sonnenberger a9bf75ec6f Kill some trailing whitespace.
SVN-Revision: 1932
2010-02-20 18:34:54 -05:00
Joerg Sonnenberger ed840be5f5 Split time field documentation into a separate man page.
SVN-Revision: 1931
2010-02-20 18:32:40 -05:00
Joerg Sonnenberger 6c0ea656b1 Spell my own name :)
SVN-Revision: 1930
2010-02-20 18:02:28 -05:00
Joerg Sonnenberger 6e6394c499 Simplify the line reader:
- Do not allocate a buffer in advance, it will be reallocated on the
first round anyway.
- Allocate one more byte to allow always terminating the buffer.
- Use strcpsn to compute the end of line. This slightly changes the
behavior for NUL in text lines as they are no longer truncated.

SVN-Revision: 1929
2010-02-20 17:59:56 -05:00
Joerg Sonnenberger 32630958d2 Add a basic man page for the linkresolver code.
SVN-Revision: 1928
2010-02-20 17:53:26 -05:00
Joerg Sonnenberger fbe92e3712 Provide a sane default strategy for the various formats.
zip and ar don't do hardlinks, so work like old-cpio.
shar is like tar.
Default to old-cpio as fallback as it is the least problematic of the
three options.

SVN-Revision: 1926
2010-02-20 16:23:11 -05:00
Joerg Sonnenberger e06d401cb8 Make sure that len is initialised even if no filters are present.
SVN-Revision: 1925
2010-02-20 16:21:21 -05:00
Joerg Sonnenberger 3412e94abb Fix spacing
SVN-Revision: 1924
2010-02-20 14:51:15 -05:00
Joerg Sonnenberger d99377118a The second argument for lafe_line_reader has been changed to a boolean
in revision 1385, catch up.

SVN-Revision: 1922
2010-02-20 12:06:36 -05:00
Joerg Sonnenberger 6886dab08e Do not leak setup_xattr into the global name space.
SVN-Revision: 1917
2010-02-19 19:20:25 -05:00
Joerg Sonnenberger 3645b64eea fnmatch(3) is no longer use, so don't check for it.
SVN-Revision: 1142
2009-05-29 02:38:52 -04:00
Joerg Sonnenberger f614018c25 Replace zip_encode with the normal endian functions.
SVN-Revision: 1137
2009-05-27 11:39:26 -04:00
Joerg Sonnenberger 35164b8c50 Replace archive_write_zip_set_deflate and archive_write_zip_set_store
with options.

SVN-Revision: 1136
2009-05-26 16:21:39 -04:00
Joerg Sonnenberger 2347c1e8dc Writing zip is fully supported.
SVN-Revision: 1135
2009-05-26 16:03:29 -04:00
Joerg Sonnenberger b48b3609b7 Hard-wire buffer size only once and check for malloc error.
SVN-Revision: 1134
2009-05-26 16:01:19 -04:00
Joerg Sonnenberger f2578566f7 Refactor crc32 into a separate file and provide a version that actually
works.

SVN-Revision: 1133
2009-05-26 15:37:20 -04:00
Joerg Sonnenberger 8d4e1443d0 Make compression support work.
SVN-Revision: 1132
2009-05-26 14:58:08 -04:00
Joerg Sonnenberger 0f8d79b197 Match unknown filesize property for zip archives in the assertions.
Test the deflate case if zlib.h is present, otherwise use store.

SVN-Revision: 1131
2009-05-26 14:57:06 -04:00
Joerg Sonnenberger 1b5bb0052a Include real crc32 if zlib.h is missing.
SVN-Revision: 1130
2009-05-26 14:54:07 -04:00
Joerg Sonnenberger 6f54fdaec8 Explicitly request store mode.
SVN-Revision: 1129
2009-05-26 13:21:51 -04:00
Joerg Sonnenberger df65feab35 Fix test case to compute CRC32 correctly.
SVN-Revision: 1128
2009-05-26 12:36:55 -04:00
Joerg Sonnenberger 62982467f6 Correctly write compressed size to the central catalog.
SVN-Revision: 1127
2009-05-26 12:27:38 -04:00