Commit Graph

179 Commits

Author SHA1 Message Date
kientzle
b2f9cd5319 MFC 1.77: Support --posix as a synonym for --format=pax, for
GNU tar compatibility.
2007-09-27 03:42:59 +00:00
kientzle
a261d75a7b MFC: Enable -p by default for root, which seems to be what
most people expect.
2007-08-25 04:38:44 +00:00
kientzle
479b110eb7 Update bsdtar version to 1.9 to match libarchive.
At this point, bsdtar is identical to that in 7-CURRENT
except for one small behavioral change that I'm debating.
2007-08-25 04:35:21 +00:00
kientzle
0035d116be MFC: Use libarchive's new security checks (which are much faster)
instead of implementing them in bsdtar.
2007-08-25 04:33:13 +00:00
kientzle
e9b353931e MFC a comment. 2007-08-25 04:28:04 +00:00
kientzle
8162e7625f MFC: Don't try to store file body if there was a fatal error writing
the header.
2007-08-25 04:27:41 +00:00
kientzle
7bd343d4a0 MFC additional manpage comments to more widely publicize some
of bsdtar's key features.
2007-08-25 04:26:00 +00:00
kientzle
379f6c564c MFC --use-compress-program support. 2007-08-25 04:24:52 +00:00
kientzle
3210c203d5 MFC include guards. 2007-08-25 04:21:18 +00:00
kientzle
dbe00e79e2 MFC generic path comparisons. There was some old code
to ignore leading "./" that was there to allow us to
compare path names with strcmp().  Comparing pathnames
syntactically is a bit more complex than that, so
encapsulate it in a new utility function and use that instead.
2007-08-25 04:19:55 +00:00
kientzle
26f3bc4cf4 MFC corrected error handling on extraction. 2007-08-25 04:14:28 +00:00
kientzle
5b2f302121 MFC some miscellaneous casts to correct printing of
numerical UIDs, GIDs, and device numbers in tar -tv output.a
2007-08-25 04:11:47 +00:00
kientzle
67ca34cecd MFC refactored code to copy entry from one archive to another.
This is the code that implements the @<archive> interpolation
feature.
2007-08-25 04:08:45 +00:00
kientzle
c7d49f6377 MFC whitespace fixes. 2007-08-25 03:59:52 +00:00
kientzle
17d37094df MFC refactored platform configuration.
Separate platform-specific config into config_freebsd.h.
Changes to Makefile and bsdtar_platform.h to use this instead
of coding the FreeBSD configuration into bsdtar_platform.h
2007-08-25 03:58:25 +00:00
kientzle
f8775dae64 MFC corrected arg handling: -o is not the same as --no-same-owner
-o means different things depending on the mode in order to
     preserve both GNU and POSIX compatibility
   --no-same-owner always means the same thing, regardless of other options
2007-08-07 05:38:10 +00:00
kientzle
0ec9eae153 MFC two minor fixes:
* Message when exiting with a deferred error code.
  * Don't crash on bad use of -W
2007-08-07 05:34:38 +00:00
kientzle
9a81c1a075 MFC include guards and fill in extra definitions in bsdtar_platform.h. 2007-08-07 05:30:22 +00:00
kientzle
dae5cffde9 MFC include guards; add HAVE_GRP_H and HAVE_PWD_H to bsdtar_platform.h 2007-08-07 05:22:07 +00:00
kientzle
17f7e17e2d MFC include guards in bsdtar.c. Also, add HAVE_TIME_H to
bsdtar_platform.h so they actually work correctly.
2007-08-07 05:10:18 +00:00
kientzle
7e6d8214b3 MFC comments in bsdtar.c. 2007-08-07 05:05:03 +00:00
kientzle
f988cf8ca7 MFC matching.c 1.11: Guard includes to improve portability. 2007-08-07 04:55:21 +00:00
kientzle
a7f99471a8 MFC tree.c 1.8:
* Correct crash when files are removed during a traversal
 * Streamline some of the dir and link checks
 * Clarify comments
 * Guard header includes for portability

Update bsdtar_platform.h to reflect that FreeBSD does
indeed have <errno.h>.
2007-08-07 04:49:55 +00:00
kientzle
b738b64515 MFC 1.9: Fill in some missing casts. 2007-08-07 04:38:22 +00:00
cperciva
c42cf872d1 MFC rev. 1.62: Complain about "tar -c /path/which/does/not/exist". 2007-05-24 09:27:50 +00:00
cperciva
3f174ff209 MFC revisions 1.5[6789]:
* Remove unused pathlen argument from write_entry function.
 * Fix logic bug in deciding if do_chdir should be called.
 * Don't consider an lstat(2) failure to be an error.
 * Correct warning message when lstat(2) fails.
2007-03-21 15:15:57 +00:00
cvs2svn
22b21ad204 This commit was manufactured by cvs2svn to create branch 'RELENG_6'. 2007-03-14 18:20:37 +00:00
kientzle
96743a0bb4 MFC 1.22: Re-enable archiving of ACLs 2007-03-11 19:46:56 +00:00
kientzle
939d23bb36 MFC write.c 1.54. This implements -r support for empty or
nonexistent files and corrects the bad handling of files that
change size during archiving.

PR: bin/108607
PR: bin/108990
2007-02-25 07:24:44 +00:00
kientzle
0c542aca20 MFC copyright message correction: Make this a standard vanilla
2-clause BSD license, update the year to 2007.
2007-01-27 06:48:39 +00:00
cperciva
206b24dde9 MFC revisions 1.48-1.50:
* Print error messages where appropriate, and print the right one.
 * Properly handle errors in archive_write_close.
 * Correct resource leak in @<archive> handling.
2007-01-23 12:13:29 +00:00
cperciva
4c5a39da78 MFC revisions 1.68-1.71 of bsdtar.c, 1.25 of bsdtar.h:
* Remove nonexistant -F option from getopts string.
* Correct the names of some options.
* Check for -U and --strip-components options in inappropriate contexts.
2006-12-26 05:27:49 +00:00
kientzle
3ece0b55ea MFC: getdate.y 1.7
Fix "1 day ago", "yesterday" and similar relative-time phrases
when parsing dates.

PR: bin/104934: bug in some date handling of bsdtar
Approved by: re
2006-11-10 16:09:13 +00:00
kientzle
aeb96a35d9 MFC 1.47: Remove two unused variables 2006-08-15 03:54:41 +00:00
kientzle
5c16608d6a MFC 1.26: conditionally include sys/mkdev.h on platforms that need it. 2006-08-15 03:53:50 +00:00
kientzle
cce1fd0901 MFC bsdtar 1.2.53 to FreeBSD 6:
* Fixes bin/87911 (internal error attempting -u with empty file)
  * Fixes bin/84993 (warnings with GCC 4.1)
  * Fixes bin/95175 (core dump on nonexistent symlink)
  * Documentation fixes
  * Corrections to pathname matching
  * Portability fixes
  * Initial extended attribute support
2006-07-30 06:32:14 +00:00
simon
5f94cb1c4b MFC rev 1.31:
Use the .Fx macro.
2006-01-25 20:56:17 +00:00
kientzle
7a3cda744e MFC 1.65: Correct error message from incorrect use of --format.
PR: bin/86915
2005-11-06 22:27:21 +00:00
kientzle
4151fc111d MFC 1.17: Correctly detect NL_LANG_INFO.
PR: bin/88013
2005-11-06 22:24:27 +00:00
delphij
b1029e7f15 MFC 1.64 by kientzle:
The bsdtar_warnc() reporting function requires the program name to be
set up before it is called, so move the progname initialization before
the first possible call to bsdtar_warnc().

Thanks to: Stanislav Sedov
PR: bin/83366

Approved by:	re (scottl)
2005-09-20 07:48:00 +00:00
ru
07317cc4f0 Fixed troff warnings.
Approved by:	re (blanket manpages)
2005-06-27 07:37:01 +00:00
kientzle
5fd4825f3c Clarify some error messages. 2005-05-08 06:25:15 +00:00
kientzle
839391fc8e bsdtar now uses the "tree" package instead of "fts" for walking
directory heirarchies.
2005-04-24 05:53:37 +00:00
kientzle
d4451ef08b Correct autoconf/automake invocation to work with devel/gnu-auto* from
ports.

Thanks to: Dag-Erling Sm?rgrav (des@)
2005-04-23 18:44:25 +00:00
kientzle
c4cef244d6 Minor fix to the configure logic to properly detect ACL support. 2005-04-23 18:41:28 +00:00
kientzle
2fe0aef3f1 Overhaul getdate.y. In particular, remove minutes-based logic
(combine with existing seconds-based), treat '-' as punctuation rather
than a negative number indicator (eliminates several special cases),
use a single list of special words instead of several separate lists,
use table-driven abbreviation logic (eliminate duplicate word entries
and special-case abbreviation and plural handling).  The result is
shorter, simpler (judging from comments, earlier maintainers didn't
understand the special handling for "negative years"), handles more
cases (e.g., "tu" is now a recognized abbreviation for "tuesday",
"3rd" is now equivalent to "third") and it has 2 fewer shift/reduce
conflicts.
2005-04-23 18:38:32 +00:00
murray
9097797b6a Point users to tcsh(1) for information about shell globbing patterns,
rather than 'XXXX'.

MFC after:	1 week
2005-04-19 16:06:04 +00:00
kientzle
6857f1e3f7 A very minor tweak to the handling of leading '/' characters. 2005-04-17 19:46:50 +00:00
kientzle
f666e865e6 A number of fixes to the autoconf-generated build system. In
particular, acl support is no longer enabled on FreeBSD 4, acl support
should be correctly enabled on Linux, dirent.d_namlen should be
correctly detected on platforms that support it.

Thanks to: Greg Lewis, Juergen Lock, and Jaakko Heinonen
2005-04-17 19:43:37 +00:00
kientzle
b27e034c99 Configure script needs to test for dirent.d_namlen.
Thanks to: Juergen Lock
2005-04-17 17:53:24 +00:00